[libcamera-devel] [PATCH 1/2] DNI: Enforce IPA isolation and set log file path

Laurent Pinchart laurent.pinchart at ideasonboard.com
Mon Jul 12 01:16:28 CEST 2021


Hi Umang,

On Thu, Jul 08, 2021 at 01:51:44PM +0530, Umang Jain wrote:
> ---
>  src/ipa/ipu3/ipu3.cpp         | 2 ++
>  src/libcamera/ipa_manager.cpp | 1 +
>  2 files changed, 3 insertions(+)
> 
> diff --git a/src/ipa/ipu3/ipu3.cpp b/src/ipa/ipu3/ipu3.cpp
> index 31a3c006..623c27b7 100644
> --- a/src/ipa/ipu3/ipu3.cpp
> +++ b/src/ipa/ipu3/ipu3.cpp
> @@ -12,6 +12,7 @@
>  #include <linux/v4l2-controls.h>
>  
>  #include <libcamera/base/log.h>
> +#include <libcamera/logging.h>
>  
>  #include <libcamera/buffer.h>
>  #include <libcamera/control_ids.h>
> @@ -39,6 +40,7 @@ class IPAIPU3 : public IPAIPU3Interface
>  public:
>  	int init([[maybe_unused]] const IPASettings &settings) override
>  	{
> +		logSetFile("/tmp/isolated.log");
>  		return 0;
>  	}
>  	int start() override;
> diff --git a/src/libcamera/ipa_manager.cpp b/src/libcamera/ipa_manager.cpp
> index b4606c61..5d8ddae1 100644
> --- a/src/libcamera/ipa_manager.cpp
> +++ b/src/libcamera/ipa_manager.cpp
> @@ -258,6 +258,7 @@ unsigned int IPAManager::addDir(const char *libDir, unsigned int maxDepth)
>  
>  bool IPAManager::isSignatureValid([[maybe_unused]] IPAModule *ipa) const
>  {
> +	return false;

You may be interested in "[PATCH 3/3] libcamera: ipa_manager: Allow
forcing IPA module isolation" that I have just sent.

>  #if HAVE_IPA_PUBKEY
>  	File file{ ipa->path() };
>  	if (!file.open(File::ReadOnly))

-- 
Regards,

Laurent Pinchart


More information about the libcamera-devel mailing list