[{"id":27941,"web_url":"https://patchwork.libcamera.org/comment/27941/","msgid":"<enlmjtw56kjtjkcj53kyn6atdbqg5zph75ati2lueyd2a32yq6@szpnzmdxtynn>","date":"2023-10-12T08:09:25","subject":"Re: [libcamera-devel] [PATCH 04/20] ipa: rpi: Add\n\tIpaBase::platformStart() member function","submitter":{"id":143,"url":"https://patchwork.libcamera.org/api/people/143/","name":"Jacopo Mondi","email":"jacopo.mondi@ideasonboard.com"},"content":"Hi Naush\n\nOn Fri, Oct 06, 2023 at 02:19:44PM +0100, Naushir Patuck via libcamera-devel wrote:\n> Add a virtual IpaBase::platformStart() member function that is called\n> at the end of IpaBase::start(). For the IpaVc4 derived class, this\n> function does nothing, but will be used in the PiSP derived class to\n> reset internal state on startup.\n>\n> Signed-off-by: Naushir Patuck <naush@raspberrypi.com>\n> Reviewed-by: David Plowman <david.plowman@raspberrypi.com>\n\nReviewed-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>\n\nThanks\n  j\n\n> ---\n>  src/ipa/rpi/common/ipa_base.cpp | 2 ++\n>  src/ipa/rpi/common/ipa_base.h   | 1 +\n>  src/ipa/rpi/vc4/vc4.cpp         | 7 +++++++\n>  3 files changed, 10 insertions(+)\n>\n> diff --git a/src/ipa/rpi/common/ipa_base.cpp b/src/ipa/rpi/common/ipa_base.cpp\n> index 5df1998c8113..5939fe57f040 100644\n> --- a/src/ipa/rpi/common/ipa_base.cpp\n> +++ b/src/ipa/rpi/common/ipa_base.cpp\n> @@ -341,6 +341,8 @@ void IpaBase::start(const ControlList &controls, StartResult *result)\n>\n>  \tfirstStart_ = false;\n>  \tlastRunTimestamp_ = 0;\n> +\n> +\tplatformStart(controls, result);\n>  }\n>\n>  void IpaBase::mapBuffers(const std::vector<IPABuffer> &buffers)\n> diff --git a/src/ipa/rpi/common/ipa_base.h b/src/ipa/rpi/common/ipa_base.h\n> index 097f436af93b..eaa9f71182ed 100644\n> --- a/src/ipa/rpi/common/ipa_base.h\n> +++ b/src/ipa/rpi/common/ipa_base.h\n> @@ -67,6 +67,7 @@ private:\n>  \tstatic constexpr unsigned int numMetadataContexts = 16;\n>\n>  \tvirtual int32_t platformInit(const InitParams &params, InitResult *result) = 0;\n> +\tvirtual int32_t platformStart(const ControlList &controls, StartResult *result) = 0;\n>  \tvirtual int32_t platformConfigure(const ConfigParams &params, ConfigResult *result) = 0;\n>\n>  \tvirtual void platformPrepareIsp(const PrepareParams &params,\n> diff --git a/src/ipa/rpi/vc4/vc4.cpp b/src/ipa/rpi/vc4/vc4.cpp\n> index 1de0d3ccdc44..4a4d720ce7dd 100644\n> --- a/src/ipa/rpi/vc4/vc4.cpp\n> +++ b/src/ipa/rpi/vc4/vc4.cpp\n> @@ -51,6 +51,7 @@ public:\n>\n>  private:\n>  \tint32_t platformInit(const InitParams &params, InitResult *result) override;\n> +\tint32_t platformStart(const ControlList &controls, StartResult *result) override;\n>  \tint32_t platformConfigure(const ConfigParams &params, ConfigResult *result) override;\n>\n>  \tvoid platformPrepareIsp(const PrepareParams &params, RPiController::Metadata &rpiMetadata) override;\n> @@ -94,6 +95,12 @@ int32_t IpaVc4::platformInit([[maybe_unused]] const InitParams &params, [[maybe_\n>  \treturn 0;\n>  }\n>\n> +int32_t IpaVc4::platformStart([[maybe_unused]] const ControlList &controls,\n> +\t\t\t      [[maybe_unused]] StartResult *result)\n> +{\n> +\treturn 0;\n> +}\n> +\n>  int32_t IpaVc4::platformConfigure(const ConfigParams &params, [[maybe_unused]] ConfigResult *result)\n>  {\n>  \tispCtrls_ = params.ispControls;\n> --\n> 2.34.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 D384DC3272\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 12 Oct 2023 08:09:30 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 8CE7262980;\n\tThu, 12 Oct 2023 10:09:30 +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 F1A9562962\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 12 Oct 2023 10:09:28 +0200 (CEST)","from ideasonboard.com (93-61-96-190.ip145.fastwebnet.it\n\t[93.61.96.190])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id E44B0583;\n\tThu, 12 Oct 2023 10:09:25 +0200 (CEST)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1697098170;\n\tbh=ZwsksfqRg4FfyI0y65g65c8Crsn+z9vl2yKcd82LpAA=;\n\th=Date:To:References:In-Reply-To:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc:\n\tFrom;\n\tb=vWv1fOyGxHFevWVWJg0+nRraqXYR4ks+Gco7GFaJo4trppLXTlc4qjU6xFSw5Jnwp\n\tQJENbXAdF1VR42a6kM4yisX8lMvgUg9OeRwD1Yuk2FeQ+gdMszsg6lc4zuJUBghZ/l\n\tjGUPnySCosiEPxvw4Q9xrKhyruaWkcqaE+DpN9cIv1zbS/iVdc4Dd9SBuzM1d6Zmg/\n\tYUv/Jgq7ofoYYg+kfW8Fukqu/Fd3M3cROasPcgfvg4Tr0pu+gB1LY5UUPSEzQ/ESyO\n\teBC37u8MSuu1AHcFZFS+cUhYhztXsu85PIa3e/8Ny0y+Zd9kgE7QGC05KuMJme2tUb\n\t1omT+cVBxiltA==","v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1697098166;\n\tbh=ZwsksfqRg4FfyI0y65g65c8Crsn+z9vl2yKcd82LpAA=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=j/plX6/9qV753WOkZRrB6/wwV1LAn33xz/GqEJ5WH/wtU5zBTvc4BnCUPYmpGjDnn\n\tnUhhi9LfLVKZguqb0UIH8LenqlmZOtQa2z9KG1vnkS5aWoLSK03te6zDffYD+EofYA\n\tHzvIvBPAK0/KjiqeYCl3um7su26nlmvrpgOJq2/M="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"j/plX6/9\"; dkim-atps=neutral","Date":"Thu, 12 Oct 2023 10:09:25 +0200","To":"Naushir Patuck <naush@raspberrypi.com>","Message-ID":"<enlmjtw56kjtjkcj53kyn6atdbqg5zph75ati2lueyd2a32yq6@szpnzmdxtynn>","References":"<20231006132000.23504-1-naush@raspberrypi.com>\n\t<20231006132000.23504-5-naush@raspberrypi.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<20231006132000.23504-5-naush@raspberrypi.com>","Subject":"Re: [libcamera-devel] [PATCH 04/20] ipa: rpi: Add\n\tIpaBase::platformStart() member function","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":"Jacopo Mondi via libcamera-devel <libcamera-devel@lists.libcamera.org>","Reply-To":"Jacopo Mondi <jacopo.mondi@ideasonboard.com>","Cc":"libcamera-devel@lists.libcamera.org","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]