Patch Detail
Show a patch.
GET /api/1.1/patches/17526/?format=api
{ "id": 17526, "url": "https://patchwork.libcamera.org/api/1.1/patches/17526/?format=api", "web_url": "https://patchwork.libcamera.org/patch/17526/", "project": { "id": 1, "url": "https://patchwork.libcamera.org/api/1.1/projects/1/?format=api", "name": "libcamera", "link_name": "libcamera", "list_id": "libcamera_core", "list_email": "libcamera-devel@lists.libcamera.org", "web_url": "", "scm_url": "", "webscm_url": "" }, "msgid": "<20221004222903.6393-4-laurent.pinchart@ideasonboard.com>", "date": "2022-10-04T22:29:02", "name": "[libcamera-devel,v2,3/4] pipeline: rkisp1: Set bytesused before queuing parameters buffer", "commit_ref": null, "pull_url": null, "state": "accepted", "archived": false, "hash": "ac68e7764b6741719618c3a0343311469c18e5ba", "submitter": { "id": 2, "url": "https://patchwork.libcamera.org/api/1.1/people/2/?format=api", "name": "Laurent Pinchart", "email": "laurent.pinchart@ideasonboard.com" }, "delegate": null, "mbox": "https://patchwork.libcamera.org/patch/17526/mbox/", "series": [ { "id": 3531, "url": "https://patchwork.libcamera.org/api/1.1/series/3531/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=3531", "date": "2022-10-04T22:28:59", "name": "libcamera: Fix kernel deprecation warning with output buffers", "version": 2, "mbox": "https://patchwork.libcamera.org/series/3531/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/17526/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/17526/checks/", "tags": {}, "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 AC923C327C\n\tfor <parsemail@patchwork.libcamera.org>;\n\tTue, 4 Oct 2022 22:29:13 +0000 (UTC)", "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 5D2CD60AD1;\n\tWed, 5 Oct 2022 00:29:13 +0200 (CEST)", "from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 4C40660AC6\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 5 Oct 2022 00:29:12 +0200 (CEST)", "from pendragon.ideasonboard.com (62-78-145-57.bb.dnainternet.fi\n\t[62.78.145.57])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 1622BFA0;\n\tWed, 5 Oct 2022 00:29:11 +0200 (CEST)" ], "DKIM-Signature": [ "v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1664922553;\n\tbh=wnq0fDCsKrF3lIbogEVCUb6rc83T/y14IHAljEfb7IY=;\n\th=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:\n\tFrom;\n\tb=rOvEPtm/nBiPmT/UfbbxOOY8vyiViFUFjyYU5DSJsC74GScveauwKWzgfE3H3eG9E\n\tpjrqxyQWBOJoZbb+lX0kCwkJrUPTiEY2USoRyIDlrX8pnV8qFZrh7ueuOYHTRVYZJv\n\tx0pFWHdfdqQg5DdZ9JDpUMET9vhvv3vK/EWXkVflvokTJI2ODRH0Ja2v9FbTqjZMgh\n\troJRYheOOCYIsUSUc8RcWCFEhAb70My6qmNbpYYXKBchhUfJVVemDs/LMw7hAuvc+L\n\teBbZuYSfcBIvcphFEhXo3IHucXsLRz5YKm0R7r3R4D/3aDgQq2ryNrYZNetbfbkVKU\n\tJ0a3tYkJX5fAQ==", "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1664922551;\n\tbh=wnq0fDCsKrF3lIbogEVCUb6rc83T/y14IHAljEfb7IY=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=h4Fw5GDNIg5dvEMa7LT3LHlvtaQ3iC2wGJ0IMMpxq3KHwBYOgc+2rLVvkTUrs4bir\n\tKB4ZdfSp7gX28S5Igf3KMkS5d1yms70ikcqUj0E+1PTa+FniVTSn3remgrIvD1XlC/\n\tvkNH3FectvAi+2VsnPv1GX+f6bTktcZ9EAkdBaC4=" ], "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"h4Fw5GDN\"; dkim-atps=neutral", "To": "libcamera-devel@lists.libcamera.org", "Date": "Wed, 5 Oct 2022 01:29:02 +0300", "Message-Id": "<20221004222903.6393-4-laurent.pinchart@ideasonboard.com>", "X-Mailer": "git-send-email 2.35.1", "In-Reply-To": "<20221004222903.6393-1-laurent.pinchart@ideasonboard.com>", "References": "<20221004222903.6393-1-laurent.pinchart@ideasonboard.com>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "Subject": "[libcamera-devel] [PATCH v2 3/4] pipeline: rkisp1: Set bytesused\n\tbefore queuing parameters buffer", "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>", "From": "Laurent Pinchart via libcamera-devel\n\t<libcamera-devel@lists.libcamera.org>", "Reply-To": "Laurent Pinchart <laurent.pinchart@ideasonboard.com>", "Errors-To": "libcamera-devel-bounces@lists.libcamera.org", "Sender": "\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>" }, "content": "The bytesused value for the parameters buffer is initialized to 0 and\nnever set. The V4L2 API specification indicates that, for an output\nvideo device, the driver will set the bytesused value to the size of the\nplane in that case. The videobuf2 framework does so, but considers this\nas deprecated and prints a warning:\n\n[ 54.375534] use of bytesused == 0 is deprecated and will be removed in the future,\n[ 54.388026] use the actual size instead.\n\nFix it by setting bytesused to the correct value before queuing the\nparameters buffer.\n\nSigned-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>\nReviewed-by: Jacopo Mondi <jacopo@jmondi.org>\n---\n src/libcamera/pipeline/rkisp1/rkisp1.cpp | 4 ++++\n 1 file changed, 4 insertions(+)", "diff": "diff --git a/src/libcamera/pipeline/rkisp1/rkisp1.cpp b/src/libcamera/pipeline/rkisp1/rkisp1.cpp\nindex 25fbf9f1a0a9..455ee2a0a711 100644\n--- a/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n+++ b/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n@@ -13,6 +13,7 @@\n #include <queue>\n \n #include <linux/media-bus-format.h>\n+#include <linux/rkisp1-config.h>\n \n #include <libcamera/base/log.h>\n #include <libcamera/base/utils.h>\n@@ -32,6 +33,7 @@\n #include \"libcamera/internal/camera_sensor.h\"\n #include \"libcamera/internal/delayed_controls.h\"\n #include \"libcamera/internal/device_enumerator.h\"\n+#include \"libcamera/internal/framebuffer.h\"\n #include \"libcamera/internal/ipa_manager.h\"\n #include \"libcamera/internal/media_device.h\"\n #include \"libcamera/internal/pipeline_handler.h\"\n@@ -362,6 +364,8 @@ void RkISP1CameraData::paramFilled(unsigned int frame)\n \tif (!info)\n \t\treturn;\n \n+\tinfo->paramBuffer->_d()->metadata().planes()[0].bytesused =\n+\t\tsizeof(struct rkisp1_params_cfg);\n \tpipe->param_->queueBuffer(info->paramBuffer);\n \tpipe->stat_->queueBuffer(info->statBuffer);\n \n", "prefixes": [ "libcamera-devel", "v2", "3/4" ] }