Patch Detail
Show a patch.
GET /api/patches/23159/?format=api
{ "id": 23159, "url": "https://patchwork.libcamera.org/api/patches/23159/?format=api", "web_url": "https://patchwork.libcamera.org/patch/23159/", "project": { "id": 1, "url": "https://patchwork.libcamera.org/api/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": "<20250411123641.2144530-3-stefan.klug@ideasonboard.com>", "date": "2025-04-11T12:36:30", "name": "[v2,2/9] utils: gen-debug-controls: Fix handling of controls that appear multiple times", "commit_ref": null, "pull_url": null, "state": "superseded", "archived": false, "hash": "c4142d95279d58403cc00e7a3b97f99a6d06fef8", "submitter": { "id": 184, "url": "https://patchwork.libcamera.org/api/people/184/?format=api", "name": "Stefan Klug", "email": "stefan.klug@ideasonboard.com" }, "delegate": null, "mbox": "https://patchwork.libcamera.org/patch/23159/mbox/", "series": [ { "id": 5121, "url": "https://patchwork.libcamera.org/api/series/5121/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=5121", "date": "2025-04-11T12:36:28", "name": "Wdr preparations", "version": 2, "mbox": "https://patchwork.libcamera.org/series/5121/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/23159/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/23159/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 BE86CC327D\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 11 Apr 2025 12:36:53 +0000 (UTC)", "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 7249468A9D;\n\tFri, 11 Apr 2025 14:36:53 +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 3E23468A90\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 11 Apr 2025 14:36:52 +0200 (CEST)", "from ideasonboard.com (unknown\n\t[IPv6:2a00:6020:448c:6c00:5b21:2ad5:1023:7179])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id DBCAF735;\n\tFri, 11 Apr 2025 14:34: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=\"V2yDVZSm\"; dkim-atps=neutral", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1744374893;\n\tbh=PfG1v9RSZ8jfa4zZ4EAddT/V3talYJ18VZsMaO34lEE=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=V2yDVZSmSHgj3SyD77/R0fizQxFqMlP2PeY8Jm46sDVnCNeVTv7JQh8hQS0lDA6jh\n\tclOzCVXZyEWogwXHOUvhYo1BdQ3+0qOBgiqWZtqB5sMgn6ZjReYKTBDGtd+dgWia9r\n\tnEDd67OGtPJwplsQFvpO1jdLUA2kKPvod1nOEe28=", "From": "Stefan Klug <stefan.klug@ideasonboard.com>", "To": "libcamera-devel@lists.libcamera.org", "Cc": "Stefan Klug <stefan.klug@ideasonboard.com>,\n\tKieran Bingham <kieran.bingham@ideasonboard.com>", "Subject": "[PATCH v2 2/9] utils: gen-debug-controls: Fix handling of controls\n\tthat appear multiple times", "Date": "Fri, 11 Apr 2025 14:36:30 +0200", "Message-ID": "<20250411123641.2144530-3-stefan.klug@ideasonboard.com>", "X-Mailer": "git-send-email 2.43.0", "In-Reply-To": "<20250411123641.2144530-1-stefan.klug@ideasonboard.com>", "References": "<20250411123641.2144530-1-stefan.klug@ideasonboard.com>", "MIME-Version": "1.0", "Content-Transfer-Encoding": "8bit", "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>" }, "content": "Allow usage of the same debug control in multiple places as long as all\ninstances are of the same type and size.\n\nSigned-off-by: Stefan Klug <stefan.klug@ideasonboard.com>\nAcked-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n\n---\n\nChanges in v2:\n- Collected tag\n---\n utils/gen-debug-controls.py | 11 ++++++++++-\n 1 file changed, 10 insertions(+), 1 deletion(-)", "diff": "diff --git a/utils/gen-debug-controls.py b/utils/gen-debug-controls.py\nindex 53c8fa70d76d..ff22b986475e 100755\n--- a/utils/gen-debug-controls.py\n+++ b/utils/gen-debug-controls.py\n@@ -96,6 +96,7 @@ def main(argv):\n controls_map[k] = v\n \n obsolete_names = list(controls_map.keys())\n+ found_by_name = {}\n \n for m in matches:\n if not m.type:\n@@ -111,6 +112,12 @@ def main(argv):\n if m.size is not None:\n desc['size'] = m.size\n \n+ c = found_by_name.setdefault(m.name, m)\n+ if c.type != m.type or c.size != m.size:\n+ logger.error(\n+ f\"Found multiple entries for control '{m.name}' with differing type or size\")\n+ return 1\n+\n if m.name in controls_map:\n # Can't use == for modified check because of the special yaml dicts.\n update_needed = False\n@@ -127,7 +134,9 @@ def main(argv):\n controls_map[m.name].clear()\n controls_map[m.name].update(desc)\n \n- obsolete_names.remove(m.name)\n+ # Don't try to remove more than once in case control was found multiple files.\n+ if m.name in obsolete_names:\n+ obsolete_names.remove(m.name)\n else:\n logger.info(f\"Add control '{m.name}'\")\n insert_before = len(controls)\n", "prefixes": [ "v2", "2/9" ] }