[{"id":26937,"web_url":"https://patchwork.libcamera.org/comment/26937/","msgid":"<e2l6anttgrufc3reb6nrqwargqmbfhsg4mbuiploj2acoq6ebu@soljmm6i23hg>","date":"2023-04-26T16:12:57","subject":"Re: [libcamera-devel] [PATCH 02/13] libcamera: ipa_proxy: Allow a\n\tprefix for the configuration file","submitter":{"id":143,"url":"https://patchwork.libcamera.org/api/people/143/","name":"Jacopo Mondi","email":"jacopo.mondi@ideasonboard.com"},"content":"Hi Naush\n\nOn Wed, Apr 26, 2023 at 02:10:46PM +0100, Naushir Patuck via libcamera-devel wrote:\n> Add a prefix parameter to IPAProxy::configurationFile(). This prefix is\n> added to the search path when locating IPA configuration files in the\n> system directories.\n>\n> For example, the system directories etc/libcamera/ipa/<prefix>/ and\n> share/libcamera/ipa/<prefix>/ will be used to search for the IPA\n> configuration files.\n>\n> Signed-off-by: Naushir Patuck <naush@raspberrypi.com>\n> ---\n>  include/libcamera/internal/ipa_proxy.h             |  3 ++-\n>  src/libcamera/ipa_proxy.cpp                        | 11 +++++++----\n>  src/libcamera/pipeline/ipu3/ipu3.cpp               |  4 ++--\n>  src/libcamera/pipeline/raspberrypi/raspberrypi.cpp |  2 +-\n>  src/libcamera/pipeline/rkisp1/rkisp1.cpp           |  4 ++--\n>  src/libcamera/pipeline/vimc/vimc.cpp               |  2 +-\n>  test/ipa/ipa_interface_test.cpp                    |  2 +-\n>  7 files changed, 16 insertions(+), 12 deletions(-)\n>\n> diff --git a/include/libcamera/internal/ipa_proxy.h b/include/libcamera/internal/ipa_proxy.h\n> index 781c8b623605..4ec357425fd3 100644\n> --- a/include/libcamera/internal/ipa_proxy.h\n> +++ b/include/libcamera/internal/ipa_proxy.h\n> @@ -31,7 +31,8 @@ public:\n>\n>  \tbool isValid() const { return valid_; }\n>\n> -\tstd::string configurationFile(const std::string &file) const;\n> +\tstd::string configurationFile(const std::string &file,\n> +\t\t\t\t      const std::string &prefix) const;\n\nThis could have a default value of \"\" for platforms that do not need a\nvendor prefix\n\nWith that\nReviewed-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>\n\nThanks\n  j\n\n>\n>  protected:\n>  \tstd::string resolvePath(const std::string &file) const;\n> diff --git a/src/libcamera/ipa_proxy.cpp b/src/libcamera/ipa_proxy.cpp\n> index 3f2cc6b89f60..4a27b0a993fa 100644\n> --- a/src/libcamera/ipa_proxy.cpp\n> +++ b/src/libcamera/ipa_proxy.cpp\n> @@ -72,6 +72,7 @@ IPAProxy::~IPAProxy()\n>  /**\n>   * \\brief Retrieve the absolute path to an IPA configuration file\n>   * \\param[in] name The configuration file name\n> + * \\param[in] prefix The configuration directory prefix when searching system paths\n>   *\n>   * This function locates the configuration file for an IPA and returns its\n>   * absolute path. It searches the following directories, in order:\n> @@ -80,8 +81,8 @@ IPAProxy::~IPAProxy()\n>   *   environment variable ; or\n>   * - If libcamera is not installed, the src/ipa/ directory within the source\n>   *   tree ; otherwise\n> - * - The system sysconf (etc/libcamera/ipa) and the data (share/libcamera/ipa/)\n> - *   directories.\n> + * - The system sysconf (etc/libcamera/ipa/<prefix>/) and the data\n> + *   (share/libcamera/ipa/<prefix>/) directories.\n>   *\n>   * The system directories are not searched if libcamera is not installed.\n>   *\n> @@ -92,7 +93,8 @@ IPAProxy::~IPAProxy()\n>   * \\return The full path to the IPA configuration file, or an empty string if\n>   * no configuration file can be found\n>   */\n> -std::string IPAProxy::configurationFile(const std::string &name) const\n> +std::string IPAProxy::configurationFile(const std::string &name,\n> +\t\t\t\t\tconst std::string &prefix) const\n>  {\n>  \tstruct stat statbuf;\n>  \tint ret;\n> @@ -139,7 +141,8 @@ std::string IPAProxy::configurationFile(const std::string &name) const\n>  \t} else {\n>  \t\t/* Else look in the system locations. */\n>  \t\tfor (const auto &dir : utils::split(IPA_CONFIG_DIR, \":\")) {\n> -\t\t\tstd::string confPath = dir + \"/\" + ipaName + \"/\" + name;\n> +\t\t\tstd::string confPath = dir + \"/\" + prefix + \"/\" +\n> +\t\t\t\t\t       ipaName + \"/\" + name;\n>  \t\t\tret = stat(confPath.c_str(), &statbuf);\n>  \t\t\tif (ret == 0 && (statbuf.st_mode & S_IFMT) == S_IFREG)\n>  \t\t\t\treturn confPath;\n> diff --git a/src/libcamera/pipeline/ipu3/ipu3.cpp b/src/libcamera/pipeline/ipu3/ipu3.cpp\n> index 355cb0cb76b8..a48d7e78d25e 100644\n> --- a/src/libcamera/pipeline/ipu3/ipu3.cpp\n> +++ b/src/libcamera/pipeline/ipu3/ipu3.cpp\n> @@ -1186,9 +1186,9 @@ int IPU3CameraData::loadIPA()\n>  \t * The API tuning file is made from the sensor name. If the tuning file\n>  \t * isn't found, fall back to the 'uncalibrated' file.\n>  \t */\n> -\tstd::string ipaTuningFile = ipa_->configurationFile(sensor->model() + \".yaml\");\n> +\tstd::string ipaTuningFile = ipa_->configurationFile(sensor->model() + \".yaml\", \"\");\n>  \tif (ipaTuningFile.empty())\n> -\t\tipaTuningFile = ipa_->configurationFile(\"uncalibrated.yaml\");\n> +\t\tipaTuningFile = ipa_->configurationFile(\"uncalibrated.yaml\", \"\");\n>\n>  \tret = ipa_->init(IPASettings{ ipaTuningFile, sensor->model() },\n>  \t\t\t sensorInfo, sensor->controls(), &ipaControls_);\n> diff --git a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> index 0060044143cc..a4fff28bf198 100644\n> --- a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> +++ b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> @@ -1668,7 +1668,7 @@ int RPiCameraData::loadIPA(ipa::RPi::IPAInitResult *result)\n>  \t\tstd::string model = sensor_->model();\n>  \t\tif (isMonoSensor(sensor_))\n>  \t\t\tmodel += \"_mono\";\n> -\t\tconfigurationFile = ipa_->configurationFile(model + \".json\");\n> +\t\tconfigurationFile = ipa_->configurationFile(model + \".json\", \"\");\n>  \t} else {\n>  \t\tconfigurationFile = std::string(configFromEnv);\n>  \t}\n> diff --git a/src/libcamera/pipeline/rkisp1/rkisp1.cpp b/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n> index 8a30fe061d04..e338cdee2a2d 100644\n> --- a/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n> +++ b/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n> @@ -349,13 +349,13 @@ int RkISP1CameraData::loadIPA(unsigned int hwRevision)\n>  \tstd::string ipaTuningFile;\n>  \tchar const *configFromEnv = utils::secure_getenv(\"LIBCAMERA_RKISP1_TUNING_FILE\");\n>  \tif (!configFromEnv || *configFromEnv == '\\0') {\n> -\t\tipaTuningFile = ipa_->configurationFile(sensor_->model() + \".yaml\");\n> +\t\tipaTuningFile = ipa_->configurationFile(sensor_->model() + \".yaml\", \"\");\n>  \t\t/*\n>  \t\t * If the tuning file isn't found, fall back to the\n>  \t\t * 'uncalibrated' configuration file.\n>  \t\t */\n>  \t\tif (ipaTuningFile.empty())\n> -\t\t\tipaTuningFile = ipa_->configurationFile(\"uncalibrated.yaml\");\n> +\t\t\tipaTuningFile = ipa_->configurationFile(\"uncalibrated.yaml\", \"\");\n>  \t} else {\n>  \t\tipaTuningFile = std::string(configFromEnv);\n>  \t}\n> diff --git a/src/libcamera/pipeline/vimc/vimc.cpp b/src/libcamera/pipeline/vimc/vimc.cpp\n> index 204f5ad73f6d..5fbabcc5763d 100644\n> --- a/src/libcamera/pipeline/vimc/vimc.cpp\n> +++ b/src/libcamera/pipeline/vimc/vimc.cpp\n> @@ -472,7 +472,7 @@ bool PipelineHandlerVimc::match(DeviceEnumerator *enumerator)\n>\n>  \tdata->ipa_->paramsBufferReady.connect(data.get(), &VimcCameraData::paramsBufferReady);\n>\n> -\tstd::string conf = data->ipa_->configurationFile(\"vimc.conf\");\n> +\tstd::string conf = data->ipa_->configurationFile(\"vimc.conf\", \"\");\n>  \tFlags<ipa::vimc::TestFlag> inFlags = ipa::vimc::TestFlag::Flag2;\n>  \tFlags<ipa::vimc::TestFlag> outFlags;\n>  \tdata->ipa_->init(IPASettings{ conf, data->sensor_->model() },\n> diff --git a/test/ipa/ipa_interface_test.cpp b/test/ipa/ipa_interface_test.cpp\n> index 051ef96e7ed2..b25de222b9b4 100644\n> --- a/test/ipa/ipa_interface_test.cpp\n> +++ b/test/ipa/ipa_interface_test.cpp\n> @@ -105,7 +105,7 @@ protected:\n>  \t\t}\n>\n>  \t\t/* Test initialization of IPA module. */\n> -\t\tstd::string conf = ipa_->configurationFile(\"vimc.conf\");\n> +\t\tstd::string conf = ipa_->configurationFile(\"vimc.conf\", \"\");\n>  \t\tFlags<ipa::vimc::TestFlag> inFlags;\n>  \t\tFlags<ipa::vimc::TestFlag> outFlags;\n>  \t\tint ret = ipa_->init(IPASettings{ conf, \"vimc\" },\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 55EE8C3272\n\tfor <parsemail@patchwork.libcamera.org>;\n\tWed, 26 Apr 2023 16:13:03 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id BB9FD627D6;\n\tWed, 26 Apr 2023 18:13:02 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 01E41627D4\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 26 Apr 2023 18:13:00 +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 529BDC7E;\n\tWed, 26 Apr 2023 18:12:49 +0200 (CEST)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1682525582;\n\tbh=P4hxNjsOWK9olS/IdgKD5ZjdaFs9Pe+Y79MWolldq3o=;\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=v+8g1Si3FIqL3Hx1NC5ukusJ8qmE3UU53cQ/C6fmfTUf79lmADg3pkvlWfT6DJTZf\n\tzTb9fhvEtlqEC90yQvszqRcww8tDv0DLijFz0ds9IOc6vaHqxDVlWpqfq/C6fR24OH\n\tudu6g2FIRohckyb5sYdMIFZpxJc+0Q9moCrij1FTAz8uHpxKdLbp2SXmWD4tNYq42A\n\tVioxjiOBBTZjunhwnpVFA1oZNBG/xSRpwv6Yw0K0AhrrWMM5xE64HzGvI7sCkS+Uwi\n\tFENKe0DDhxo2CcGWHp+2trJSTEc586Ry/d5A8gr61WiXFV3B81N5lrx/9kC5NIf4oX\n\tahTXC/kbAw7Sg==","v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1682525569;\n\tbh=P4hxNjsOWK9olS/IdgKD5ZjdaFs9Pe+Y79MWolldq3o=;\n\th=Date:From:To:Cc:Subject:References:In-Reply-To:From;\n\tb=JDw2vyMU1jsgfYeJne4wwsPdFZ16Vv2AZ4Ec0AxnVrt5m6PjnjyMhTVNO46P1tbOz\n\tDgsDSj9g+Mx11KdY/ix7dgflASOTT/zP99OwZm9p+csiRCrd+jP+kjEB7xfT8N40UY\n\tK46dqMggMPzm4N7+3MnM4j2EKp7pohYcZizOGIPM="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key; \n\tunprotected) header.d=ideasonboard.com\n\theader.i=@ideasonboard.com\n\theader.b=\"JDw2vyMU\"; dkim-atps=neutral","Date":"Wed, 26 Apr 2023 18:12:57 +0200","To":"Naushir Patuck <naush@raspberrypi.com>","Message-ID":"<e2l6anttgrufc3reb6nrqwargqmbfhsg4mbuiploj2acoq6ebu@soljmm6i23hg>","References":"<20230426131057.21550-1-naush@raspberrypi.com>\n\t<20230426131057.21550-3-naush@raspberrypi.com>","MIME-Version":"1.0","Content-Type":"text/plain; charset=utf-8","Content-Disposition":"inline","In-Reply-To":"<20230426131057.21550-3-naush@raspberrypi.com>","Subject":"Re: [libcamera-devel] [PATCH 02/13] libcamera: ipa_proxy: Allow a\n\tprefix for the configuration file","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>"}},{"id":26946,"web_url":"https://patchwork.libcamera.org/comment/26946/","msgid":"<CAEmqJPpjvxY6Q+-oCnNVAABKBOdytRwnDQXs2k-u23UN5BvjpA@mail.gmail.com>","date":"2023-04-27T06:53:00","subject":"Re: [libcamera-devel] [PATCH 02/13] libcamera: ipa_proxy: Allow a\n\tprefix for the configuration file","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 review on this and other patches in the series!\n\nOn Wed, 26 Apr 2023 at 17:13, Jacopo Mondi\n<jacopo.mondi@ideasonboard.com> wrote:\n>\n> Hi Naush\n>\n> On Wed, Apr 26, 2023 at 02:10:46PM +0100, Naushir Patuck via libcamera-devel wrote:\n> > Add a prefix parameter to IPAProxy::configurationFile(). This prefix is\n> > added to the search path when locating IPA configuration files in the\n> > system directories.\n> >\n> > For example, the system directories etc/libcamera/ipa/<prefix>/ and\n> > share/libcamera/ipa/<prefix>/ will be used to search for the IPA\n> > configuration files.\n> >\n> > Signed-off-by: Naushir Patuck <naush@raspberrypi.com>\n> > ---\n> >  include/libcamera/internal/ipa_proxy.h             |  3 ++-\n> >  src/libcamera/ipa_proxy.cpp                        | 11 +++++++----\n> >  src/libcamera/pipeline/ipu3/ipu3.cpp               |  4 ++--\n> >  src/libcamera/pipeline/raspberrypi/raspberrypi.cpp |  2 +-\n> >  src/libcamera/pipeline/rkisp1/rkisp1.cpp           |  4 ++--\n> >  src/libcamera/pipeline/vimc/vimc.cpp               |  2 +-\n> >  test/ipa/ipa_interface_test.cpp                    |  2 +-\n> >  7 files changed, 16 insertions(+), 12 deletions(-)\n> >\n> > diff --git a/include/libcamera/internal/ipa_proxy.h b/include/libcamera/internal/ipa_proxy.h\n> > index 781c8b623605..4ec357425fd3 100644\n> > --- a/include/libcamera/internal/ipa_proxy.h\n> > +++ b/include/libcamera/internal/ipa_proxy.h\n> > @@ -31,7 +31,8 @@ public:\n> >\n> >       bool isValid() const { return valid_; }\n> >\n> > -     std::string configurationFile(const std::string &file) const;\n> > +     std::string configurationFile(const std::string &file,\n> > +                                   const std::string &prefix) const;\n>\n> This could have a default value of \"\" for platforms that do not need a\n> vendor prefix\n\nI did consider this, but backed out at the last minute because I thought we may\nwant to have the prefix explicit.  However, since you have separately suggested\nit as well, I'll make the change.  I'll reply-to this patch with the update.\n\nRegards,\nNaush\n\n>\n> With that\n> Reviewed-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>\n>\n> Thanks\n>   j\n>\n> >\n> >  protected:\n> >       std::string resolvePath(const std::string &file) const;\n> > diff --git a/src/libcamera/ipa_proxy.cpp b/src/libcamera/ipa_proxy.cpp\n> > index 3f2cc6b89f60..4a27b0a993fa 100644\n> > --- a/src/libcamera/ipa_proxy.cpp\n> > +++ b/src/libcamera/ipa_proxy.cpp\n> > @@ -72,6 +72,7 @@ IPAProxy::~IPAProxy()\n> >  /**\n> >   * \\brief Retrieve the absolute path to an IPA configuration file\n> >   * \\param[in] name The configuration file name\n> > + * \\param[in] prefix The configuration directory prefix when searching system paths\n> >   *\n> >   * This function locates the configuration file for an IPA and returns its\n> >   * absolute path. It searches the following directories, in order:\n> > @@ -80,8 +81,8 @@ IPAProxy::~IPAProxy()\n> >   *   environment variable ; or\n> >   * - If libcamera is not installed, the src/ipa/ directory within the source\n> >   *   tree ; otherwise\n> > - * - The system sysconf (etc/libcamera/ipa) and the data (share/libcamera/ipa/)\n> > - *   directories.\n> > + * - The system sysconf (etc/libcamera/ipa/<prefix>/) and the data\n> > + *   (share/libcamera/ipa/<prefix>/) directories.\n> >   *\n> >   * The system directories are not searched if libcamera is not installed.\n> >   *\n> > @@ -92,7 +93,8 @@ IPAProxy::~IPAProxy()\n> >   * \\return The full path to the IPA configuration file, or an empty string if\n> >   * no configuration file can be found\n> >   */\n> > -std::string IPAProxy::configurationFile(const std::string &name) const\n> > +std::string IPAProxy::configurationFile(const std::string &name,\n> > +                                     const std::string &prefix) const\n> >  {\n> >       struct stat statbuf;\n> >       int ret;\n> > @@ -139,7 +141,8 @@ std::string IPAProxy::configurationFile(const std::string &name) const\n> >       } else {\n> >               /* Else look in the system locations. */\n> >               for (const auto &dir : utils::split(IPA_CONFIG_DIR, \":\")) {\n> > -                     std::string confPath = dir + \"/\" + ipaName + \"/\" + name;\n> > +                     std::string confPath = dir + \"/\" + prefix + \"/\" +\n> > +                                            ipaName + \"/\" + name;\n> >                       ret = stat(confPath.c_str(), &statbuf);\n> >                       if (ret == 0 && (statbuf.st_mode & S_IFMT) == S_IFREG)\n> >                               return confPath;\n> > diff --git a/src/libcamera/pipeline/ipu3/ipu3.cpp b/src/libcamera/pipeline/ipu3/ipu3.cpp\n> > index 355cb0cb76b8..a48d7e78d25e 100644\n> > --- a/src/libcamera/pipeline/ipu3/ipu3.cpp\n> > +++ b/src/libcamera/pipeline/ipu3/ipu3.cpp\n> > @@ -1186,9 +1186,9 @@ int IPU3CameraData::loadIPA()\n> >        * The API tuning file is made from the sensor name. If the tuning file\n> >        * isn't found, fall back to the 'uncalibrated' file.\n> >        */\n> > -     std::string ipaTuningFile = ipa_->configurationFile(sensor->model() + \".yaml\");\n> > +     std::string ipaTuningFile = ipa_->configurationFile(sensor->model() + \".yaml\", \"\");\n> >       if (ipaTuningFile.empty())\n> > -             ipaTuningFile = ipa_->configurationFile(\"uncalibrated.yaml\");\n> > +             ipaTuningFile = ipa_->configurationFile(\"uncalibrated.yaml\", \"\");\n> >\n> >       ret = ipa_->init(IPASettings{ ipaTuningFile, sensor->model() },\n> >                        sensorInfo, sensor->controls(), &ipaControls_);\n> > diff --git a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> > index 0060044143cc..a4fff28bf198 100644\n> > --- a/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> > +++ b/src/libcamera/pipeline/raspberrypi/raspberrypi.cpp\n> > @@ -1668,7 +1668,7 @@ int RPiCameraData::loadIPA(ipa::RPi::IPAInitResult *result)\n> >               std::string model = sensor_->model();\n> >               if (isMonoSensor(sensor_))\n> >                       model += \"_mono\";\n> > -             configurationFile = ipa_->configurationFile(model + \".json\");\n> > +             configurationFile = ipa_->configurationFile(model + \".json\", \"\");\n> >       } else {\n> >               configurationFile = std::string(configFromEnv);\n> >       }\n> > diff --git a/src/libcamera/pipeline/rkisp1/rkisp1.cpp b/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n> > index 8a30fe061d04..e338cdee2a2d 100644\n> > --- a/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n> > +++ b/src/libcamera/pipeline/rkisp1/rkisp1.cpp\n> > @@ -349,13 +349,13 @@ int RkISP1CameraData::loadIPA(unsigned int hwRevision)\n> >       std::string ipaTuningFile;\n> >       char const *configFromEnv = utils::secure_getenv(\"LIBCAMERA_RKISP1_TUNING_FILE\");\n> >       if (!configFromEnv || *configFromEnv == '\\0') {\n> > -             ipaTuningFile = ipa_->configurationFile(sensor_->model() + \".yaml\");\n> > +             ipaTuningFile = ipa_->configurationFile(sensor_->model() + \".yaml\", \"\");\n> >               /*\n> >                * If the tuning file isn't found, fall back to the\n> >                * 'uncalibrated' configuration file.\n> >                */\n> >               if (ipaTuningFile.empty())\n> > -                     ipaTuningFile = ipa_->configurationFile(\"uncalibrated.yaml\");\n> > +                     ipaTuningFile = ipa_->configurationFile(\"uncalibrated.yaml\", \"\");\n> >       } else {\n> >               ipaTuningFile = std::string(configFromEnv);\n> >       }\n> > diff --git a/src/libcamera/pipeline/vimc/vimc.cpp b/src/libcamera/pipeline/vimc/vimc.cpp\n> > index 204f5ad73f6d..5fbabcc5763d 100644\n> > --- a/src/libcamera/pipeline/vimc/vimc.cpp\n> > +++ b/src/libcamera/pipeline/vimc/vimc.cpp\n> > @@ -472,7 +472,7 @@ bool PipelineHandlerVimc::match(DeviceEnumerator *enumerator)\n> >\n> >       data->ipa_->paramsBufferReady.connect(data.get(), &VimcCameraData::paramsBufferReady);\n> >\n> > -     std::string conf = data->ipa_->configurationFile(\"vimc.conf\");\n> > +     std::string conf = data->ipa_->configurationFile(\"vimc.conf\", \"\");\n> >       Flags<ipa::vimc::TestFlag> inFlags = ipa::vimc::TestFlag::Flag2;\n> >       Flags<ipa::vimc::TestFlag> outFlags;\n> >       data->ipa_->init(IPASettings{ conf, data->sensor_->model() },\n> > diff --git a/test/ipa/ipa_interface_test.cpp b/test/ipa/ipa_interface_test.cpp\n> > index 051ef96e7ed2..b25de222b9b4 100644\n> > --- a/test/ipa/ipa_interface_test.cpp\n> > +++ b/test/ipa/ipa_interface_test.cpp\n> > @@ -105,7 +105,7 @@ protected:\n> >               }\n> >\n> >               /* Test initialization of IPA module. */\n> > -             std::string conf = ipa_->configurationFile(\"vimc.conf\");\n> > +             std::string conf = ipa_->configurationFile(\"vimc.conf\", \"\");\n> >               Flags<ipa::vimc::TestFlag> inFlags;\n> >               Flags<ipa::vimc::TestFlag> outFlags;\n> >               int ret = ipa_->init(IPASettings{ conf, \"vimc\" },\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 20AF9BDCBD\n\tfor <parsemail@patchwork.libcamera.org>;\n\tThu, 27 Apr 2023 06:53:15 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 733BB627D6;\n\tThu, 27 Apr 2023 08:53:14 +0200 (CEST)","from mail-yb1-xb2f.google.com (mail-yb1-xb2f.google.com\n\t[IPv6:2607:f8b0:4864:20::b2f])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 30DDC61EAF\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tThu, 27 Apr 2023 08:53:12 +0200 (CEST)","by mail-yb1-xb2f.google.com with SMTP id\n\t3f1490d57ef6-b8f5121503eso12067507276.1\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tWed, 26 Apr 2023 23:53:12 -0700 (PDT)"],"DKIM-Signature":["v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1682578394;\n\tbh=Ir0Q6pWKOhzjVGcTsoICloPexCyJj/ZBol7brOuScsU=;\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=DUohojkVsVdTQv/iUxpnaL6NqnZ1TljJQcC7kXGDEnvTmqxpPguX8e/+o15zL9xJS\n\tPUkkFIcl4yfhjfhxyxhmzjpYhldpg+pulpSj45aQcaHwQmt2RU5KEzC7ykl9Ab8jWU\n\txHVx5ezSwpbaWlIKyXOdWwr6qJW2yprs9ijscoiOQWhWca/XbSyVAyS6bd7tpT/g6N\n\txOgRm2WxBFeprrTSFd/JXPzPhSUpjiGATuEgAS/jAoe/K6d9UBhaSvoK0Ydvbfwg3O\n\tzNJac1c0IUNauGgmctuPWVn1pAm1W8kfaqRGhpCCQNCwlTXwHUwEow8KMw0aBR9XYd\n\tLPrqeT1YVKx2Q==","v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=raspberrypi.com; s=google; t=1682578391; x=1685170391;\n\th=cc:to:subject:message-id:date:from:in-reply-to:references\n\t:mime-version:from:to:cc:subject:date:message-id:reply-to;\n\tbh=wUn3+rZIS6wGKhpfYm2Bt+oSxHzy2FGPefmbhCzDGGM=;\n\tb=kE/GjPU8QSw6IrhbLY0vPL4J3jZ57pBK+0EBiP9XdR78Q4iRHixZicE16JRaTzaX9H\n\tZrh08ihrhMRaFzTNSXNfqOdwvry9bCZ63+Mg9gR8NX0FdLKul+6a19lIUbRDb/luEIv0\n\t54FBSpp7O/PidojFy1QpQFooAoEDEbH9+lltJ4/99jiHHgcoF+cJ4Ufun7AtKFDyxBws\n\tmgQVabWmehiaQtornvDjJy6mqGVwDqjDnw5mLrlJLbLQCEdtekxMWzXEMjW7HdiPbZ5t\n\tsi03QqiwfND29APw//AGuvCbpsqtRIrtzzoafRUrE5uPpRvhDvQUDb3RyHEgLGwnd4h8\n\toUeQ=="],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (2048-bit key; \n\tunprotected) header.d=raspberrypi.com\n\theader.i=@raspberrypi.com\n\theader.b=\"kE/GjPU8\"; dkim-atps=neutral","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n\td=1e100.net; s=20221208; t=1682578391; x=1685170391;\n\th=cc:to:subject:message-id:date:from:in-reply-to:references\n\t:mime-version:x-gm-message-state:from:to:cc:subject:date:message-id\n\t:reply-to;\n\tbh=wUn3+rZIS6wGKhpfYm2Bt+oSxHzy2FGPefmbhCzDGGM=;\n\tb=dGiBA5d5Qx35LvttfKJHkm/UJXJqPVq3YCySc9PJM3YbeZTybjeQLuOfx3/LG9Brs5\n\t8nLwTabjKk/t7+Aj6JFEeVjWE6Keie9XFenaOLL6r7ryUX+FMBAnJPHcjd4x/KCk7Bhx\n\ts/gYYuecT2zY7YF4jtys4j3Syy8I16zfHiVrud9EJxTKoxAnYMzJ2o3+LX5tl3ZdYoog\n\tCkAf2hxP+Eizk8fp31N0Do/7QCl6S2SyiME7pmwdaHlXJYrQtHUK/kre5TjbC2VJyj4Y\n\t+B4UDD+o1p/L7tGJwlGmP334xpWKfn0wWpJeYF89OXclzU+ffak2bOWE8GZX+iXZQiGW\n\toNYg==","X-Gm-Message-State":"AC+VfDy9JDPqHTwyrB2Y0EiVXuInY1/sh2PGRyRabBzGX4y33CWgcB4Y\n\tF0n1mbph+bnlIK/PBzNT3SjN6NwbutKkZvsTAbaK1Q==","X-Google-Smtp-Source":"ACHHUZ58XsnkbpIpjAMdtBiVQgUBLZuBFfbHE2+hylfMiFbhrukzGDJYWoR8/6Kk7R2Cmt0hj1QUMAgcbwBJcZUo6FQ=","X-Received":"by 2002:a05:6902:150a:b0:b94:6b2d:80dc with SMTP id\n\tq10-20020a056902150a00b00b946b2d80dcmr318531ybu.10.1682578390721;\n\tWed, 26 Apr 2023 23:53:10 -0700 (PDT)","MIME-Version":"1.0","References":"<20230426131057.21550-1-naush@raspberrypi.com>\n\t<20230426131057.21550-3-naush@raspberrypi.com>\n\t<e2l6anttgrufc3reb6nrqwargqmbfhsg4mbuiploj2acoq6ebu@soljmm6i23hg>","In-Reply-To":"<e2l6anttgrufc3reb6nrqwargqmbfhsg4mbuiploj2acoq6ebu@soljmm6i23hg>","Date":"Thu, 27 Apr 2023 07:53:00 +0100","Message-ID":"<CAEmqJPpjvxY6Q+-oCnNVAABKBOdytRwnDQXs2k-u23UN5BvjpA@mail.gmail.com>","To":"Jacopo Mondi <jacopo.mondi@ideasonboard.com>","Content-Type":"text/plain; charset=\"UTF-8\"","Subject":"Re: [libcamera-devel] [PATCH 02/13] libcamera: ipa_proxy: Allow a\n\tprefix for the configuration file","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@lists.libcamera.org","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"}}]