[{"id":33784,"web_url":"https://patchwork.libcamera.org/comment/33784/","msgid":"<174343918102.3394313.13982179408319832385@ping.linuxembedded.co.uk>","date":"2025-03-31T16:39:41","subject":"Re: [PATCH 6/9] pipeline: rkisp1: Add more info when parameter queue\n\tfails","submitter":{"id":4,"url":"https://patchwork.libcamera.org/api/people/4/","name":"Kieran Bingham","email":"kieran.bingham@ideasonboard.com"},"content":"Quoting Stefan Klug (2025-03-31 15:43:45)\n> When the rkisp1 driver of the running kernel supports less parameter\n> types than the libcamera build and such a parameter is used, queuing of\n> the parameter buffer fails with -EINVAL. For the time being we have no\n> way to query the kernel for supported parameter types at runtime. So at\n> least print a error message that points the user in that direction.\n> \n> Signed-off-by: Stefan Klug <stefan.klug@ideasonboard.com>\n> ---\n>  src/libcamera/pipeline/rkisp1/rkisp1.cpp | 10 +++++++++-\n>  1 file changed, 9 insertions(+), 1 deletion(-)\n> \n> diff --git a/src/libcamera/pipeline/rkisp1/rkisp1.cpp b/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n> index 52633fe3cb85..132ab40fdbf7 100644\n> --- a/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n> +++ b/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n> @@ -409,7 +409,15 @@ void RkISP1CameraData::paramsComputed(unsigned int frame, unsigned int bytesused\n>                 return;\n>  \n>         info->paramBuffer->_d()->metadata().planes()[0].bytesused = bytesused;\n> -       pipe->param_->queueBuffer(info->paramBuffer);\n> +\n> +       int ret = pipe->param_->queueBuffer(info->paramBuffer);\n> +       if (ret < 0) {\n> +               LOG(RkISP1, Error) << \"Failed to queue parameter buffer. \"\n> +                                  << \"Maybe the kernel doesn't support the\"\n> +                                  << \" required parameter types.\";\n\nCan we report ret so we can know /what/ error it is incase it's not\n-EINVAL ?\n\n\n\n> +               return;\n> +       }\n> +\n>         pipe->stat_->queueBuffer(info->statBuffer);\n>  \n>         if (info->mainPathBuffer)\n> -- \n> 2.43.0\n>","headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id CA015C3213\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 31 Mar 2025 16:39:45 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 8325D68985;\n\tMon, 31 Mar 2025 18:39:45 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 4E9E168967\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 31 Mar 2025 18:39:44 +0200 (CEST)","from pendragon.ideasonboard.com\n\t(cpc89244-aztw30-2-0-cust6594.18-1.cable.virginm.net [86.31.185.195])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id BE5CE725;\n\tMon, 31 Mar 2025 18:37:52 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"GeK5WeH1\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1743439072;\n\tbh=L5Zz7QUP9rKsQ42ek2Tq1kPGykW6Zy5ABnKQNU+RapY=;\n\th=In-Reply-To:References:Subject:From:Cc:To:Date:From;\n\tb=GeK5WeH1V5l6L4Gc+gNfo/SQYBup/fJLikPM5FTRshNPyWW+IcdJfWmm3Uyadeose\n\t+oCaeChh42Pn2KaThEcJurJ8fTUl+cpnu01LmvrnOvJUm+aT0LYeeIhJDzmzohNCU2\n\tzR49W2rNsT/358fiOgB3D8/hfcE9S2ywZ+4hR0vc=","Content-Type":"text/plain; charset=\"utf-8\"","MIME-Version":"1.0","Content-Transfer-Encoding":"quoted-printable","In-Reply-To":"<20250331144352.736700-7-stefan.klug@ideasonboard.com>","References":"<20250331144352.736700-1-stefan.klug@ideasonboard.com>\n\t<20250331144352.736700-7-stefan.klug@ideasonboard.com>","Subject":"Re: [PATCH 6/9] pipeline: rkisp1: Add more info when parameter queue\n\tfails","From":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Cc":"Stefan Klug <stefan.klug@ideasonboard.com>","To":"Stefan Klug <stefan.klug@ideasonboard.com>,\n\tlibcamera-devel@lists.libcamera.org","Date":"Mon, 31 Mar 2025 17:39:41 +0100","Message-ID":"<174343918102.3394313.13982179408319832385@ping.linuxembedded.co.uk>","User-Agent":"alot/0.10","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]