Patch Detail
Show a patch.
GET /api/1.1/patches/20221/?format=api
{ "id": 20221, "url": "https://patchwork.libcamera.org/api/1.1/patches/20221/?format=api", "web_url": "https://patchwork.libcamera.org/patch/20221/", "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": "<20240606115223.14868-1-naush@raspberrypi.com>", "date": "2024-06-06T11:52:23", "name": "pipeline: rpi: Don't validate configuration in generateConfiguration()", "commit_ref": "634bc7838f879c208df1915b2259e2a7f8dcefd7", "pull_url": null, "state": "accepted", "archived": false, "hash": "8b7a4f2e6a4bbbe7118a07309381df426554c4ef", "submitter": { "id": 34, "url": "https://patchwork.libcamera.org/api/1.1/people/34/?format=api", "name": "Naushir Patuck", "email": "naush@raspberrypi.com" }, "delegate": null, "mbox": "https://patchwork.libcamera.org/patch/20221/mbox/", "series": [ { "id": 4368, "url": "https://patchwork.libcamera.org/api/1.1/series/4368/?format=api", "web_url": "https://patchwork.libcamera.org/project/libcamera/list/?series=4368", "date": "2024-06-06T11:52:23", "name": "pipeline: rpi: Don't validate configuration in generateConfiguration()", "version": 1, "mbox": "https://patchwork.libcamera.org/series/4368/mbox/" } ], "comments": "https://patchwork.libcamera.org/api/patches/20221/comments/", "check": "pending", "checks": "https://patchwork.libcamera.org/api/patches/20221/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 2AF9EBD87C\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 6 Jun 2024 11:52:33 +0000 (UTC)", "from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 3213565457;\n\tThu, 6 Jun 2024 13:52:32 +0200 (CEST)", "from mail-ej1-x630.google.com (mail-ej1-x630.google.com\n\t[IPv6:2a00:1450:4864:20::630])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id C03DF634CA\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 6 Jun 2024 13:52:30 +0200 (CEST)", "by mail-ej1-x630.google.com with SMTP id\n\ta640c23a62f3a-a68e7538cfaso112279866b.0\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 06 Jun 2024 04:52:30 -0700 (PDT)", "from localhost.localdomain ([188.39.149.98])\n\tby smtp.gmail.com with ESMTPSA id\n\ta640c23a62f3a-a6c8072889fsm86339666b.195.2024.06.06.04.52.28\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tThu, 06 Jun 2024 04:52:29 -0700 (PDT)" ], "Authentication-Results": "lancelot.ideasonboard.com; dkim=pass (2048-bit key;\n\tunprotected) header.d=raspberrypi.com header.i=@raspberrypi.com\n\theader.b=\"S5o4Rx1s\"; dkim-atps=neutral", "DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google; t=1717674750; x=1718279550;\n\tdarn=lists.libcamera.org; \n\th=content-transfer-encoding:mime-version:message-id:date:subject:cc\n\t:to:from:from:to:cc:subject:date:message-id:reply-to;\n\tbh=vFR/ITuS5PPZLWFzKLH1uaJixrP9NmLk/7hwZSLNjrU=;\n\tb=S5o4Rx1sOTY8viUEwIEFCsWe1YQE89GrA1txIvamnNx4k7Z+IELMGDX2lwplnr5ZxT\n\taH0JNC0DopADJb6g7diws1zeELnx5bHqdofFUT4Cdh0N9zgTt2E/Cu6uE/qXN5jJk4PI\n\t+JJ0Q6UIH+4ms8z6d8se4kTcb+kWf7p9csp4q7F3A2GMqPeePr9tBVQ8Stxx6RL9l/d+\n\tyCaJ9DdHtN/vkMgR8ssnxRtX8Sr1H3eOKwWUs5lEsy7j9KxEpAfkH6jK7WENa2+3nxYc\n\t4Q+EHJDppCVAazQ88Wwzp4c2ICx/po1WZQ1qYQyiKSASk4lmWye06o7/ZEhKzuwoeGb9\n\tDotw==", "X-Google-DKIM-Signature": "v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1717674750; x=1718279550;\n\th=content-transfer-encoding:mime-version:message-id:date:subject:cc\n\t:to:from:x-gm-message-state:from:to:cc:subject:date:message-id\n\t:reply-to;\n\tbh=vFR/ITuS5PPZLWFzKLH1uaJixrP9NmLk/7hwZSLNjrU=;\n\tb=Gm7h0eafLzNOgmOZY2TV4FOaV39jP/IKsLghw2r51KWPKSqgJ7SAZ/WlFaE1WccHcU\n\t+6xn1cgpkiciHqKzDK5Y52bHJ8ZxDKIvUwani7Gj7qnsKYD/Zzesrwb68eToZUf4J+uw\n\ttTNsNwFrhntQdskdEVRUwa/kdAR0sMKxxYsGADj5aMA0SLQGLLc1UzTOvXHBQVpWRLQX\n\tC52PypeC6yLJb3XS7PeMrwHeCHaB7Y8lR7NHfF/cw8F3HVwGJM3n8YbDADwP8BJwIwN0\n\t60Zh/w4ACNZXLBJ2xMMNtrTuweZGzqIj8y5fUoSH5y3M6CoHtd0A8bXH3uWiMLA97y8I\n\tJEBQ==", "X-Gm-Message-State": "AOJu0YyfnGRoIt3tsX+jV1nfNYlf+ZsBkSdtBdzU5ZzdDgOJexA7eu9g\n\toilq9Fp5x9rB4+p7XQbyZTq0+nRI7L2OuJIxYXAsAMdNdwpGJgl7eyUsM0kZxKzf+MhT/HC97za\n\t3", "X-Google-Smtp-Source": "AGHT+IFNJamITPjVYmioMTx99FikAquKGIFXzy54bnqCKtYvRxqJ74Sb9ArsAUyj1OYCjcxC5bEsJQ==", "X-Received": "by 2002:a17:906:840a:b0:a68:adab:101f with SMTP id\n\ta640c23a62f3a-a699fa9c13bmr335001366b.18.1717674749656; \n\tThu, 06 Jun 2024 04:52:29 -0700 (PDT)", "From": "Naushir Patuck <naush@raspberrypi.com>", "To": "libcamera-devel@lists.libcamera.org", "Cc": "Naushir Patuck <naush@raspberrypi.com>", "Subject": "[PATCH] pipeline: rpi: Don't validate configuration in\n\tgenerateConfiguration()", "Date": "Thu, 6 Jun 2024 12:52:23 +0100", "Message-Id": "<20240606115223.14868-1-naush@raspberrypi.com>", "X-Mailer": "git-send-email 2.34.1", "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": "generateConfiguration() called validate() as a final step, causing the\nstride and frameSize fields in StreamConfiguration to be filled in based\non the pixel format and width/height.\n\nIf a user application did not clear the stride field when setting up a\ncustom pixel format and width/height, the pipeline handler would respect\nthis stride and possibly overallocate buffers with a larger stride than\nneeded.\n\nFix this by removing the call to validate() completely, leaving the\nstride and frameSize fields defaulting to 0. Removal of this call is\ninconsequential as we hard-code a valid configuration for Raspberry Pi\nplatforms in generateConfiguration().\n\nBug: https://github.com/raspberrypi/libcamera/issues/138\nBug: https://github.com/raspberrypi/libcamera/issues/141\nSigned-off-by: Naushir Patuck <naush@raspberrypi.com>\n---\n src/libcamera/pipeline/rpi/common/pipeline_base.cpp | 2 --\n 1 file changed, 2 deletions(-)", "diff": "diff --git a/src/libcamera/pipeline/rpi/common/pipeline_base.cpp b/src/libcamera/pipeline/rpi/common/pipeline_base.cpp\nindex 289af5165766..3041fd1ed9fd 100644\n--- a/src/libcamera/pipeline/rpi/common/pipeline_base.cpp\n+++ b/src/libcamera/pipeline/rpi/common/pipeline_base.cpp\n@@ -496,8 +496,6 @@ PipelineHandlerBase::generateConfiguration(Camera *camera, Span<const StreamRole\n \t\tconfig->addConfiguration(cfg);\n \t}\n \n-\tconfig->validate();\n-\n \treturn config;\n }\n \n", "prefixes": [] }