[{"id":35955,"web_url":"https://patchwork.libcamera.org/comment/35955/","msgid":"<857bxonvyl.fsf@mzamazal-thinkpadp1gen7.tpbc.csb>","date":"2025-09-24T07:36:18","subject":"Re: [PATCH 1/5] ipa: software_isp: Fix\n\tcontext_.configuration.agc.againMin init","submitter":{"id":177,"url":"https://patchwork.libcamera.org/api/people/177/","name":"Milan Zamazal","email":"mzamazal@redhat.com"},"content":"Hi Hans,\n\nthank you for the patch.\n\nHans de Goede <hansg@kernel.org> writes:\n\n> Currently context_.configuration.agc.againMin is not initialized\n> when the control reports a non 0 minumum gain value.\n>\n> So far only the againMin == 0 case was handled and\n> context_.configuration.agc.againMin was left unset otherwise.\n>\n> Signed-off-by: Hans de Goede <hansg@kernel.org>\n\nReviewed-by: Milan Zamazal <mzamazal@redhat.com>\n\n> ---\n>  src/ipa/simple/soft_simple.cpp | 4 +++-\n>  1 file changed, 3 insertions(+), 1 deletion(-)\n>\n> diff --git a/src/ipa/simple/soft_simple.cpp b/src/ipa/simple/soft_simple.cpp\n> index c94c4cd55..e70439ee5 100644\n> --- a/src/ipa/simple/soft_simple.cpp\n> +++ b/src/ipa/simple/soft_simple.cpp\n> @@ -246,7 +246,9 @@ int IPASoftSimple::configure(const IPAConfigInfo &configInfo)\n>  \t\t * other) we limit the range of the gain values used.\n>  \t\t */\n>  \t\tcontext_.configuration.agc.againMax = againMax;\n> -\t\tif (!againMin) {\n> +\t\tif (againMin) {\n> +\t\t\tcontext_.configuration.agc.againMin = againMin;\n> +\t\t} else {\n>  \t\t\tLOG(IPASoft, Warning)\n>  \t\t\t\t<< \"Minimum gain is zero, that can't be linear\";\n>  \t\t\tcontext_.configuration.agc.againMin =","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 AE8E3C328C\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed, 24 Sep 2025 07:42:18 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 2F3016B5F9;\n\tWed, 24 Sep 2025 09:42:17 +0200 (CEST)","from us-smtp-delivery-124.mimecast.com\n\t(us-smtp-delivery-124.mimecast.com [170.10.129.124])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id B71486B5C2\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 24 Sep 2025 09:37:00 +0200 (CEST)","from mail-wr1-f72.google.com (mail-wr1-f72.google.com\n\t[209.85.221.72]) by relay.mimecast.com with ESMTP with STARTTLS\n\t(version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id\n\tus-mta-509-T6wzVUCjNqyrFe3-y_5jQA-1; Wed, 24 Sep 2025 03:36:21 -0400","by mail-wr1-f72.google.com with SMTP id\n\tffacd0b85a97d-3fba0d9eb87so1455352f8f.0\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 24 Sep 2025 00:36:21 -0700 (PDT)","from mzamazal-thinkpadp1gen7.tpbc.csb ([85.93.96.130])\n\tby smtp.gmail.com with ESMTPSA id\n\t5b1f17b1804b1-46e2ab6a514sm18993425e9.22.2025.09.24.00.36.18\n\t(version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n\tWed, 24 Sep 2025 00:36:19 -0700 (PDT)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=redhat.com header.i=@redhat.com\n\theader.b=\"WznL0syw\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com;\n\ts=mimecast20190719; t=1758699383;\n\th=from:from:reply-to:subject:subject:date:date:message-id:message-id:\n\tto:to:cc:cc:mime-version:mime-version:content-type:content-type:\n\tin-reply-to:in-reply-to:references:references;\n\tbh=zdG2p8XBS0XBsjXvCKdspdmUoApgokm69KEp8SDE458=;\n\tb=WznL0sywddrKRSknKY5yx2USdzyg48GNZRIz5SJiK9aMaxLWm5L3jFst1pCphrJ8L+/kA7\n\tvrVnpcCp+rXwG5tlxLjlaNn7dW+sE25VCXDV4XzqWcCYCF9pGDJ+FVYiANQqYrYki2awRv\n\tadZqW9F6lDWL40CoBVCKeFN1yXPQQmA=","X-MC-Unique":"T6wzVUCjNqyrFe3-y_5jQA-1","X-Mimecast-MFC-AGG-ID":"T6wzVUCjNqyrFe3-y_5jQA_1758699380","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20230601; t=1758699380; x=1759304180;\n\th=mime-version:user-agent:message-id:date:references:in-reply-to\n\t:subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date\n\t:message-id:reply-to;\n\tbh=zdG2p8XBS0XBsjXvCKdspdmUoApgokm69KEp8SDE458=;\n\tb=BCBE67Ra74aVxL6V6AN/TYshjhbKarbN9/bnJCjTUDDeZmTvuj0ah7yPobocUEc1Yl\n\tOxGA37rbYjBfardJh7YY/bNY6GNt/vOIvJlQFYRl+rb2yLBdGmqcRCkCREmcf1uCRJn6\n\tBBySY3uY8t8dhhS8dtVSEW6EGbcWM7fwxU1Gn/Qo7TLJ5Wggb9l3iH6KhfWgsZPKjJuV\n\tt/5nwM4Xre/V6ACuge9hRZPuGKvdwkMvTE1DdoGCaJbCkWiIH1k9UoUP/JvetGmFqtiG\n\t2yBfi3wULzJX6K6Y/t/la2q9DUiX5BFjc3qzmcELt6hHtl2WKPb1wM3ghsNL/v7RvNVI\n\tC7iA==","X-Gm-Message-State":"AOJu0YxYFkQtte6QSNf+A+97ACdebV9paKTAMdHWlmjmbdPJcyYVhCQZ\n\tJq6R/16GWB7TQaoDXBeSWQ52kmngyJiV4inzlupdXekkB4z9tDm7J3t+rMzBYwQFc4POW0fFax/\n\tseh1JZf6FONFBLB5GzN60foyFRyHiqAhcUK5xK0i8t9KMpe6lYp+FecxJzFhxV6kROlaPZMXsbh\n\tBK/g1fDdpHU1hVpoDKF1Pge7iuZKyHzNvf4Ygontu4efSughNUG1zEVZBk88s=","X-Gm-Gg":"ASbGncvP/NK/wXrfi8E4VJC4brRfbSivfaF9YvbVfyM3gq5mYmekw8h6uRBex7eYw6u\n\tpDyKC4ks5HonVARtkes72v7uoy7ZS/GUYjGMHKZk5ebb0HIuuO96+pxPhaKUFBZUFszVnzUgU1j\n\ttkDgXJ8mErF7yf9T2ANnsZU1PzsM6joG/0WtDPm3RxiV1GrP0TKzzrwXpKp37MnEXUXGwCFISLd\n\tq0TL2+9c30HV1HSzD3s+nRcY6jv7KQRThyA+ts3qSaMCcOaTKCKU62foIBIRmnxvbkhTVhuwd2R\n\tIONxNm437IK1PKDa1dqDtBNu7rb3oFcXgWZ7UeDGDaOPhMw8F3gAaSn6ARD3iRP++g==","X-Received":["by 2002:a05:6000:2501:b0:3e7:492f:72b4 with SMTP id\n\tffacd0b85a97d-405ca2a6a7fmr5335795f8f.42.1758699380108; \n\tWed, 24 Sep 2025 00:36:20 -0700 (PDT)","by 2002:a05:6000:2501:b0:3e7:492f:72b4 with SMTP id\n\tffacd0b85a97d-405ca2a6a7fmr5335765f8f.42.1758699379652; \n\tWed, 24 Sep 2025 00:36:19 -0700 (PDT)"],"X-Google-Smtp-Source":"AGHT+IE2/Lq5vmI4VfMSjfSuyyDvLr+k+Xd02yQfAwJQuzXoYDKfu/qUB8BoEvHzysgQEz7iXp0zcw==","From":"Milan Zamazal <mzamazal@redhat.com>","To":"Hans de Goede <hansg@kernel.org>","Cc":"libcamera-devel@lists.libcamera.org","Subject":"Re: [PATCH 1/5] ipa: software_isp: Fix\n\tcontext_.configuration.agc.againMin init","In-Reply-To":"<20250923190657.21453-2-hansg@kernel.org> (Hans de Goede's\n\tmessage of \"Tue, 23 Sep 2025 21:06:53 +0200\")","References":"<20250923190657.21453-1-hansg@kernel.org>\n\t<20250923190657.21453-2-hansg@kernel.org>","Date":"Wed, 24 Sep 2025 09:36:18 +0200","Message-ID":"<857bxonvyl.fsf@mzamazal-thinkpadp1gen7.tpbc.csb>","User-Agent":"Gnus/5.13 (Gnus v5.13)","MIME-Version":"1.0","X-Mimecast-Spam-Score":"0","X-Mimecast-MFC-PROC-ID":"Thvwk0aEOQONBUz0gHULNLCe5YCC1PYflWWjycz-zgU_1758699380","X-Mimecast-Originator":"redhat.com","Content-Type":"text/plain","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>"}},{"id":35966,"web_url":"https://patchwork.libcamera.org/comment/35966/","msgid":"<175879368953.88644.13074318378223975927@isaac-ThinkPad-T16-Gen-2>","date":"2025-09-25T09:48:09","subject":"Re: [PATCH 1/5] ipa: software_isp: Fix\n\tcontext_.configuration.agc.againMin init","submitter":{"id":215,"url":"https://patchwork.libcamera.org/api/people/215/","name":"Isaac Scott","email":"isaac.scott@ideasonboard.com"},"content":"Hi Hans,\n\nThank you for the patch!\n\nQuoting Hans de Goede (2025-09-23 20:06:53)\n> Currently context_.configuration.agc.againMin is not initialized\n> when the control reports a non 0 minumum gain value.\n> \n> So far only the againMin == 0 case was handled and\n> context_.configuration.agc.againMin was left unset otherwise.\n> \n> Signed-off-by: Hans de Goede <hansg@kernel.org>\n> ---\n>  src/ipa/simple/soft_simple.cpp | 4 +++-\n>  1 file changed, 3 insertions(+), 1 deletion(-)\n> \n> diff --git a/src/ipa/simple/soft_simple.cpp b/src/ipa/simple/soft_simple.cpp\n> index c94c4cd55..e70439ee5 100644\n> --- a/src/ipa/simple/soft_simple.cpp\n> +++ b/src/ipa/simple/soft_simple.cpp\n> @@ -246,7 +246,9 @@ int IPASoftSimple::configure(const IPAConfigInfo &configInfo)\n>                  * other) we limit the range of the gain values used.\n>                  */\n>                 context_.configuration.agc.againMax = againMax;\n> -               if (!againMin) {\n> +               if (againMin) {\n> +                       context_.configuration.agc.againMin = againMin;\n> +               } else {\n\nNice!\n\nReviewed-by: Isaac Scott <isaac.scott@ideasonboard.com>\n\n>                         LOG(IPASoft, Warning)\n>                                 << \"Minimum gain is zero, that can't be linear\";\n>                         context_.configuration.agc.againMin =\n> -- \n> 2.51.0\n> \n\nBest wishes,\nIsaac","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 B382BC328C\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 25 Sep 2025 09:48:51 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id B2B8A6B5F3;\n\tThu, 25 Sep 2025 11:48:49 +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 B6EC16B5A2\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 25 Sep 2025 11:48:12 +0200 (CEST)","from thinkpad.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 D19B27E4;\n\tThu, 25 Sep 2025 11:46:47 +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=\"WfK6+JC3\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1758793607;\n\tbh=QaFEz7jPKsplc/OXeUHFY9sk6aM4i0NZb4aqW9sNRYU=;\n\th=In-Reply-To:References:Subject:From:Cc:To:Date:From;\n\tb=WfK6+JC3NGz1dDQl0GnRwlRsRcwA8FKnwMJyG+KUPyxOs6mODspn/P3P0f55HyD1Z\n\tdnmu4HIFJ5MySsCu1hMJ3lMrJbePFvoGYU5Efp3buIwNGkH04WsttXX7I140KM9yQZ\n\tSSQ+Qo6XpYmPy66tZ8lwMAC9Y/GfrtihONRhheFU=","Content-Type":"text/plain; charset=\"utf-8\"","MIME-Version":"1.0","Content-Transfer-Encoding":"quoted-printable","In-Reply-To":"<20250923190657.21453-2-hansg@kernel.org>","References":"<20250923190657.21453-1-hansg@kernel.org>\n\t<20250923190657.21453-2-hansg@kernel.org>","Subject":"Re: [PATCH 1/5] ipa: software_isp: Fix\n\tcontext_.configuration.agc.againMin init","From":"Isaac Scott <isaac.scott@ideasonboard.com>","Cc":"Hans de Goede <hansg@kernel.org>","To":"Hans de Goede <hansg@kernel.org>, libcamera-devel@lists.libcamera.org","Date":"Thu, 25 Sep 2025 10:48:09 +0100","Message-ID":"<175879368953.88644.13074318378223975927@isaac-ThinkPad-T16-Gen-2>","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>"}}]