[{"id":23935,"web_url":"https://patchwork.libcamera.org/comment/23935/","msgid":"<CAEmqJPpxfF6=Rb5T2qZw=Q-A4JaL-JD_8OWZq+PrAiPV=jhZWg@mail.gmail.com>","date":"2022-07-15T14:07:16","subject":"Re: [libcamera-devel] [PATCH] libcamera: raspberry: Fix format\n\tvalidation","submitter":{"id":34,"url":"https://patchwork.libcamera.org/api/people/34/","name":"Naushir Patuck","email":"naush@raspberrypi.com"},"content":"Hi Jacopo,\n\nThank you for your patch.\n\nOn Fri, 15 Jul 2022 at 14:56, Jacopo Mondi <jacopo@jmondi.org> wrote:\n\n> If the pixel format gets adjusted to the default NV12 format during\n> validation, it gets currently ignored and the user-supplied format is\n> used nonetheless.\n>\n> Fix it by using the adjusted pixel format.\n>\n> Signed-off-by: Jacopo Mondi <jacopo@jmondi.org>\n>\n\nLooks right to me.\n\nReviewed-by: Naushir Patuck <naush@raspberrypi.com>\n\n\n> ---\n>  src/libcamera/pipeline/raspberrypi/raspberrypi.cpp | 2 +-\n>  1 file changed, 1 insertion(+), 1 deletion(-)\n>\n> diff --git a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> index fdc24cd530c2..8c8813038483 100644\n> --- a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> +++ b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> @@ -523,7 +523,7 @@ CameraConfiguration::Status\n> RPiCameraConfiguration::validate()\n>                 }\n>\n>                 V4L2DeviceFormat format;\n> -               format.fourcc =\n> V4L2PixelFormat::fromPixelFormat(cfg.pixelFormat);\n> +               format.fourcc =\n> V4L2PixelFormat::fromPixelFormat(cfgPixFmt);\n>                 format.size = cfg.size;\n>                 format.colorSpace = cfg.colorSpace;\n>\n> --\n> 2.36.1\n>\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 DF86ABE173\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 15 Jul 2022 14:07:35 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 5D60F6330E;\n\tFri, 15 Jul 2022 16:07:35 +0200 (CEST)","from mail-lf1-x12c.google.com (mail-lf1-x12c.google.com\n\t[IPv6:2a00:1450:4864:20::12c])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 070316330A\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 15 Jul 2022 16:07:33 +0200 (CEST)","by mail-lf1-x12c.google.com with SMTP id y11so7984346lfs.6\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 15 Jul 2022 07:07:32 -0700 (PDT)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1657894055;\n\tbh=BbT2UkBAqf/sjLPaOeBqgDFtlqBr/cyPLC1Y2mJ4cTQ=;\n\th=References:In-Reply-To:Date:To:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc:\n\tFrom;\n\tb=Y6NhO3s1UnBnVaDCgC928w+nYf8PWbkvlkIJbRdGqIIdsxnapobTR3HtkoaOz0OJC\n\ts7gu5EJHHLs2cPiDhJixMmwJREzBJKJnCWrozZVdzH2Xs04Vwl00zhYMbBUH9jcLIF\n\tw8UCxZgMCT6ntVh6eekBOhTsBDLQfRPa4LLtNjEUwWCvztxaOmXcoUEuiDQ5DFkvJq\n\tmJUucDAet+lBTO58lAmqhn4y9xgKR/DuddcLzg0ZDKS78m7q3/ZdAyNUohWxHWxPzQ\n\tJi2nl8+D+YCBlHSiGG10kFVe2zshhMk3CcNLVzpHwV91GzJZ9+kd3DQiyzb0kddKrS\n\tyiOu5fXJOavVw==","v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google;\n\th=mime-version:references:in-reply-to:from:date:message-id:subject:to\n\t:cc; bh=5w0QIVlarUp4Q7rCCan/BWH7/pSridZovGfAcduDi7s=;\n\tb=Vfbd/NHulN8Qzb5ZgVBPGknRYVTJCqed3NLbYsUGdHhWBrXeXlfSBsiMYG3+mZkoq3\n\t/ikCvxae6HQYCKklyPH+57ywRlHHZ3MorS/WTDOk1599N+nxvud4Uo4kL99346L8EHG6\n\t2bpT5pfB46lFmH19yhNDU07iUsh8ezUyzoDN/bRcNWtra/eqaUj605OKeb4kFdetlNvU\n\tMh90m9mvmpZmCMUlLtOsWK+dXsFSevM44ru+vHng6k/WH4Fe3PYr8RgKGe2iJ3cR8KAV\n\tAo0R4E07juVtBpXyC/HYl/D26TxKgJ64AujPg+LuqUzNDK8EM/PMDeAHXsSfK6Tk22EM\n\tDV9Q=="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (2048-bit key; \n\tunprotected) header.d=raspberrypi.com\n\theader.i=@raspberrypi.com\n\theader.b=\"Vfbd/NHu\"; dkim-atps=neutral","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20210112;\n\th=x-gm-message-state:mime-version:references:in-reply-to:from:date\n\t:message-id:subject:to:cc;\n\tbh=5w0QIVlarUp4Q7rCCan/BWH7/pSridZovGfAcduDi7s=;\n\tb=DJ97wLJozXsLO4OFONExuLf9L9ch+6BlG01TcZmc8kUonBKh8YbLQyX/zZlWb4u9fE\n\t9tj8iddXfUmPXvkAw8/zpoJSYnprUIP6mQFVWgUIIoFkrpBYE6qgJNQTQF/16cF6Ls5e\n\t3Ykgili4MbjMVetEdMygVN5GmR5Zn+81TO8pY2l4ybtMxaVIL4VB34CX8wqExNTTf2de\n\tEfS8fGvTqDHZsChEXrJhzpgR7/oNiB0NaZDohGligBaqBsFsghaXNzhyxuFx29z5VLp+\n\t638GGSYn0rckdBQYGcgAx45qq408jOLns4n62vjEtAZNXRslZjUVaNqdtt52rfnHF8Sq\n\tWVWg==","X-Gm-Message-State":"AJIora9wXrp+dcxa2ZO2FJu8Y02c02Dm7/zp/nxUI1ALRYFqdenYhMnz\n\tcoyeVMmWdCp3IIpkSgLjxtdRfl6XE38QaOCHP6+0GA==","X-Google-Smtp-Source":"AGRyM1uBxycwfHrLAgaRb/lq24ygZ1zkDguB6JPry4yKnFY+3b7AajMHlcsKTRy4VVbL6dtU9nWQfTID9rJQz43bl7w=","X-Received":"by 2002:a05:6512:1155:b0:48a:198f:5f76 with SMTP id\n\tm21-20020a056512115500b0048a198f5f76mr4364227lfg.604.1657894052207;\n\tFri, 15 Jul 2022 07:07:32 -0700 (PDT)","MIME-Version":"1.0","References":"<20220715135609.54060-1-jacopo@jmondi.org>","In-Reply-To":"<20220715135609.54060-1-jacopo@jmondi.org>","Date":"Fri, 15 Jul 2022 15:07:16 +0100","Message-ID":"<CAEmqJPpxfF6=Rb5T2qZw=Q-A4JaL-JD_8OWZq+PrAiPV=jhZWg@mail.gmail.com>","To":"Jacopo Mondi <jacopo@jmondi.org>","Content-Type":"multipart/alternative; boundary=\"0000000000000eafbf05e3d88ac1\"","Subject":"Re: [libcamera-devel] [PATCH] libcamera: raspberry: Fix format\n\tvalidation","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":"Naushir Patuck via libcamera-devel\n\t<libcamera-devel@lists.libcamera.org>","Reply-To":"Naushir Patuck <naush@raspberrypi.com>","Cc":"libcamera devel <libcamera-devel@lists.libcamera.org>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}},{"id":23939,"web_url":"https://patchwork.libcamera.org/comment/23939/","msgid":"<165791142041.2021905.13447421474199350640@Monstersaurus>","date":"2022-07-15T18:57:00","subject":"Re: [libcamera-devel] [PATCH] libcamera: raspberry: Fix format\n\tvalidation","submitter":{"id":4,"url":"https://patchwork.libcamera.org/api/people/4/","name":"Kieran Bingham","email":"kieran.bingham@ideasonboard.com"},"content":"Quoting Jacopo Mondi via libcamera-devel (2022-07-15 14:56:09)\n> If the pixel format gets adjusted to the default NV12 format during\n> validation, it gets currently ignored and the user-supplied format is\n> used nonetheless.\n> \n> Fix it by using the adjusted pixel format.\n> \n> Signed-off-by: Jacopo Mondi <jacopo@jmondi.org>\n> ---\n>  src/libcamera/pipeline/raspberrypi/raspberrypi.cpp | 2 +-\n>  1 file changed, 1 insertion(+), 1 deletion(-)\n> \n> diff --git a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> index fdc24cd530c2..8c8813038483 100644\n> --- a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> +++ b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> @@ -523,7 +523,7 @@ CameraConfiguration::Status RPiCameraConfiguration::validate()\n>                 }\n\nAt least 'status = Adjusted' would be set above, so it wouldn't have\nbeen able to pass through an actual configuration - but indeed, the\nintention is to give a supported configuration back to the application.\n\n\nReviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>\n\n> \n>                 V4L2DeviceFormat format;\n> -               format.fourcc = V4L2PixelFormat::fromPixelFormat(cfg.pixelFormat);\n> +               format.fourcc = V4L2PixelFormat::fromPixelFormat(cfgPixFmt);\n>                 format.size = cfg.size;\n>                 format.colorSpace = cfg.colorSpace;\n> \n> --\n> 2.36.1\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 667A9BE173\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 15 Jul 2022 18:57:06 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 7D3D663312;\n\tFri, 15 Jul 2022 20:57:05 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 402106330A\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 15 Jul 2022 20:57:03 +0200 (CEST)","from pendragon.ideasonboard.com\n\t(cpc89244-aztw30-2-0-cust3082.18-1.cable.virginm.net [86.31.172.11])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id C739F993;\n\tFri, 15 Jul 2022 20:57:02 +0200 (CEST)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1657911425;\n\tbh=YDnmg7WOUDhuW86+2eZM4MWJqiYjrTuywU3vqyDTChk=;\n\th=In-Reply-To:References:To:Date:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:\n\tFrom;\n\tb=xgUnPhvCdUyVmPTVWQT57Hqsnjt2poyJYVyiyqb0LyUGO2811Tp0SM7SQNTpFuGGY\n\t7FHoc8vqdKWBV/NuzGxpzIKFaZLHJ8kyUKsSmRys9WG/zR8/C9xp2WU6JuTOj1ksIn\n\tGRqtaWm1D614sXQZXZvCdDcsed1YkAcrH2st6v4qWisgciFJjG/f2EtuXyxZ2kAQmD\n\t3/hUizZvMPGxwUALa/W837cdXEiGvh135bF/yMO59kOesWS1yrNYqTvdQAlQ+FVsSa\n\tOSPeLGBzBVpUDzhviHEacK5a8Z9gEwOOtE2/X7D2WIdsC4gHh2MMpDz4Xwx6iWyrIx\n\t6De5C6qHw+6CA==","v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1657911422;\n\tbh=YDnmg7WOUDhuW86+2eZM4MWJqiYjrTuywU3vqyDTChk=;\n\th=In-Reply-To:References:Subject:From:To:Date:From;\n\tb=CocVyqUDJ5Ay3ytrRbC6VH1Ph5hsO41v6zEICMEj1jSoT76MC1onDZNimqjzUXhRw\n\tYOEEpfXmzGK2Kg4Vv9IzIv+0JtAXW6VfsKrcrhJ+Z7FYySaX2tHr6v72drjBmmLnOw\n\tDtGydMfywjj9Ey+jol7jh0RiD5wBAFaS3OQzfO8c="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"CocVyqUD\"; dkim-atps=neutral","Content-Type":"text/plain; charset=\"utf-8\"","MIME-Version":"1.0","Content-Transfer-Encoding":"quoted-printable","In-Reply-To":"<20220715135609.54060-1-jacopo@jmondi.org>","References":"<20220715135609.54060-1-jacopo@jmondi.org>","To":"Jacopo Mondi <jacopo@jmondi.org>, libcamera-devel@lists.libcamera.org","Date":"Fri, 15 Jul 2022 19:57:00 +0100","Message-ID":"<165791142041.2021905.13447421474199350640@Monstersaurus>","User-Agent":"alot/0.10","Subject":"Re: [libcamera-devel] [PATCH] libcamera: raspberry: Fix format\n\tvalidation","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":"Kieran Bingham via libcamera-devel\n\t<libcamera-devel@lists.libcamera.org>","Reply-To":"Kieran Bingham <kieran.bingham@ideasonboard.com>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]