From patchwork Tue May 12 17:53:37 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Hans de Goede X-Patchwork-Id: 26743 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 5C30DBDB1C for ; Tue, 12 May 2026 17:53:51 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 150EA6302C; Tue, 12 May 2026 19:53:51 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=qualcomm.com header.i=@qualcomm.com header.b="KgALcLka"; dkim=pass (2048-bit key; unprotected) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="Z8iakjla"; dkim-atps=neutral Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id D2A696301E for ; Tue, 12 May 2026 19:53:48 +0200 (CEST) Received: from pps.filterd (m0279870.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 64CHlcoY075092 for ; Tue, 12 May 2026 17:53:47 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= i2SVqLF0EoJ2UahwRTlUv0JYhk8i5RAv6Q5zYgRyeJU=; b=KgALcLkaO6w5Aodf NFXt04arDgZ7i5yxq87GZ1zp1NSxTS29Yn4rXc2m9Qbwu2MFB2WWD5/HPYoAsyh6 M5gnNYjWIgbQOvR3JN62yWKfxmckILZLGem6dRB6uj5/xbtfRBpLbWsU1kEXTKCQ eAGOMbB4ChXi4RJeA/w5ZpveZ5/X8w816MeiFgKtuXCn5LM49kZo3o91nxKGVu/A 3sTswBPkPqOq7u2JguPEi9JUAFvCOOgv8ozA5XAHQ/3FvK++iYSQ99SDBVCPwj2F jHlvPqhrO4IIqZ9Cf2YqBJ7epWc8IUXKkmwap4w5KlMmEfeXlrhivWezxJpCB0YU vpZDIQ== Received: from mail-vs1-f71.google.com (mail-vs1-f71.google.com [209.85.217.71]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4e43gyhnpf-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Tue, 12 May 2026 17:53:46 +0000 (GMT) Received: by mail-vs1-f71.google.com with SMTP id ada2fe7eead31-6312af106fcso8356103137.3 for ; Tue, 12 May 2026 10:53:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1778608426; x=1779213226; darn=lists.libcamera.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=i2SVqLF0EoJ2UahwRTlUv0JYhk8i5RAv6Q5zYgRyeJU=; b=Z8iakjlacBtz+ZYyg4Ie+f+tRa5s9anBS+op0uY/6P2SsC5bESjSMOrV4aSzvstUWb Av7q021Af+onQs5jlkPwfEf6zvcTCIJtuUcaVolvzKvKHksuRab+G4A89SkfORxdMWtk Tha/8kdKuiqDgJ0VijTqH37glnHrMChn6qpKKKXUnK/c20S7uBNeeDB5NDy91MmcN3uX OMmrZBUAgBeXYSYNiNqQGf9qrHAZOO2wuFcGyOSUp2MphyRRjzxauYdMJB0NFGlCKHhT 66ksL8sApxeCvaB5JHQk+qHBXlyobFUqn9qnFJVxJnBEDkQvSXZxLtVQzqcWIg5Mn4h4 2eSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778608426; x=1779213226; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=i2SVqLF0EoJ2UahwRTlUv0JYhk8i5RAv6Q5zYgRyeJU=; b=ClfFVU3l2rwgG3fz3IZPma1GX8r3JUII8HwPQhY5CMRT5KwcbQRIKBigYK/wXRXiLT tvfeI5u1DUN17bbilTl7DiXh6UMZ/n9WzacAbyjtTmpCx+9hWV3StUKBzc9F265VfjD5 E/cuzBKAVCU2dG8Z1U0TnUSXu+uuu3sLcgBo2kfAfHFWcquYkNlUfWpclSyOpYnxIaNJ LIr2sSZHSb7kp7NFHqNDZQS/HdO1AYoWlqYPKmcEQiF8EN42GOqMSA7NH3BFFl3B0smR YYPIGyLuKYw1CMm0/Vc/Tn2sSOF6zT5ON3VVAmDQwTvEKyM1tUVtHohsAvuKuYZDeKmj x1bQ== X-Gm-Message-State: AOJu0Yy6rHAqqWxx5rcCVuqOp8qjmYwiXUlpJMpbH+Is3T/AjxfwbCDh PDAetCmQ0AGXk6V6/G/D3xXOIpnXY3XEGmcNmOtn8C9WNrwuesWYXauzShuscwhpbRtfTxZbB8N X5MD64AAPf+sUNpPlMMEUT47dmdLYqsQARj/2o/lskcwuNDWNv31wKN21ixwYeKRATydytNuYBQ R0LOdFEUxx X-Gm-Gg: Acq92OFjOg5JuW9474CvewhQZv90zCnQKfL9GXPRH8g8zLTJV/U5S20knWdTiRcmfM0 8NQytDAGVMEVSBtyhQ+AJUKPhzZGUq6ZEj6NNuR346Wqu2xHmqAxxl3M/fjntWm5UsfjXmjvf1h L/WVXvqJKsJ7oKBVNwyoDizIiZKP5A2uJ1JSVQB7qNcjC3YK1JZXyT+IsPqOuZURCvVPm2Fyp09 6ncY9H1tZX4FHRJQuK6WjHm7KcBmmxvqLeHBJOyfj1ZhsfT3+pWfWRTOYDNiQw4rWVb7HSZTt9X mYyFULvhIGS7zM0J975P9DHSF/BG42MjIbFMcp9tt3fsLMmgbM3iNFQgye9/F+Te8mgcQfTcHGp IEYGj+E6Rdm/pnD286+9eUONQSiai7xjb45lWz4z+eEjD4wr6bERDC79DlFQBgoQ3m6KBitFnJg O2hgUOo1DvfSParpQEW10tzLzIIHkrtNS4S+vV X-Received: by 2002:a05:6102:5045:b0:618:442a:9e76 with SMTP id ada2fe7eead31-630f8ed8eebmr16844300137.10.1778608425408; Tue, 12 May 2026 10:53:45 -0700 (PDT) X-Received: by 2002:a05:6102:5045:b0:618:442a:9e76 with SMTP id ada2fe7eead31-630f8ed8eebmr16844289137.10.1778608424847; Tue, 12 May 2026 10:53:44 -0700 (PDT) Received: from shalem (2001-1c00-0c32-7800-5bfa-a036-83f0-f9ec.cable.dynamic.v6.ziggo.nl. [2001:1c00:c32:7800:5bfa:a036:83f0:f9ec]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-bce128529fbsm463191566b.36.2026.05.12.10.53.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 May 2026 10:53:43 -0700 (PDT) From: Hans de Goede To: libcamera-devel@lists.libcamera.org Cc: Hans de Goede , Jacopo Mondi , Kieran Bingham , =?utf-8?q?Niklas_S=C3=B6derlund?= Subject: [PATCH v5 1/4] libcamera: Create IPA by name Date: Tue, 12 May 2026 19:53:37 +0200 Message-ID: <20260512175340.115153-2-johannes.goede@oss.qualcomm.com> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260512175340.115153-1-johannes.goede@oss.qualcomm.com> References: <20260512175340.115153-1-johannes.goede@oss.qualcomm.com> MIME-Version: 1.0 X-Authority-Analysis: v=2.4 cv=fMAJG5ae c=1 sm=1 tr=0 ts=6a03692b cx=c_pps a=P2rfLEam3zuxRRdjJWA2cw==:117 a=xqWC_Br6kY4A:10 a=IkcTkHD0fZMA:10 a=NGcC8JguVDcA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=gowsoOTTUOVcmtlkKump:22 a=P1BnusSwAAAA:8 a=EUspDBNiAAAA:8 a=L8eZCmLGBQB7CTaRy48A:9 a=3ZKOabzyN94A:10 a=QEXdDO2ut3YA:10 a=ODZdjJIeia2B_SHc_B0f:22 a=D0XLA9XvdZm18NrgonBM:22 X-Proofpoint-ORIG-GUID: EfcOVzsUr0kPzIF-C_y98HkHVdgG4mb0 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNTEyMDE4NSBTYWx0ZWRfXy7QRjaAN/d06 mO1EJoocy6Qq8JqOEAdfnp7qS4bTRQTxE3wL7x7/Gfbu/h6hTQ1cn/XRIGyK70qJqXttK4xMUbR dW265/IPrQuDcxIJFRFkWZ11l9LV3nuP51LRmG86dFVKJSB+46USlewvm+GQ1UxN5bKA/UKZ4F9 wWJF02O0AyM4EWRPF6Yw371ybDofoQrs26Ji/C8+YQDkxX8xKfl7hq/JlT9YRIn3hYVbHcyXmBE b6i3ozUpYHCvLR4vJyvaIJ8mWWRJgv8nI18MbjrJJWTziOEGx/aQb9MDHZS25GU/YbdgEmHBdWu qDA1W/zdxvmgABFHtvPZa1bPl94WXUZal5hT5QulFvXgRENy/JGyCtpvcDykzOU3w1cEWN6j4X2 zvVL4wHucjFyhaW+t+sxJrjTtKcJ8P9toPaQZIfqjHQjmV8mOHeur8pSxPGWUixscF9HvVNKP0d ZSmNem/b+wTk+hAHsuA== X-Proofpoint-GUID: EfcOVzsUr0kPzIF-C_y98HkHVdgG4mb0 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293, Aquarius:18.0.1143, Hydra:6.1.51, FMLib:17.12.100.49 definitions=2026-05-11_05,2026-05-08_02,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 impostorscore=0 suspectscore=0 malwarescore=0 clxscore=1015 spamscore=0 adultscore=0 lowpriorityscore=0 phishscore=0 bulkscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2605050000 definitions=main-2605120185 X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" Currently createIPA() / IPAManager::module() assume that there is a 1:1 relationship between pipeline handlers and IPAs and IPA matching is done based on matching the pipe to ipaModuleInfo.pipelineName[]. One way to allow using a single IPA with multiple pipelines would be to allow the IPA to declare itself compatible with more than one pipeline, turning ipaModuleInfo.pipelineName[] into e.g. a vector. But the way ipaModuleInfo is loaded as an ELF symbol requires it to be a simple flat C-struct. Instead, move the IPA creation procedure to be name-based, introducing a PipelineHandler::createIPA(name, minVer, maxVer) overload that allows to specify the name of the IPA module to match. Pipeline handlers that wants to use their name as matching criteria can continue doing so using the already existing PipelineHandler::createIPA(minVer, maxVer) overload. Signed-off-by: Jacopo Mondi Reviewed-by: Kieran Bingham Tested-by: Niklas Söderlund Signed-off-by: Hans de Goede --- Changes in v5: - Rebase on top of db998e618aaa ("libcamera: pipeline_handler: Add createIPA() function") which moved the createIPA() wrapper for pipeline-handlers into the PipelineHandler class Changes in v4: - Rebase, change author to Hans' new email address Changes in v1 from Hans' original patch: - Slightly different approach addressing the review comments on Hans' v1 by creating an overload for PipelineHandler::createIPA() that allows pipelines to specify the IPA module name. --- include/libcamera/internal/ipa_manager.h | 6 ++--- include/libcamera/internal/ipa_module.h | 4 +-- include/libcamera/internal/pipeline_handler.h | 9 ++++++- src/libcamera/ipa_manager.cpp | 8 +++--- src/libcamera/ipa_module.cpp | 14 +++++------ src/libcamera/pipeline_handler.cpp | 25 +++++++++++++++++-- 6 files changed, 47 insertions(+), 19 deletions(-) diff --git a/include/libcamera/internal/ipa_manager.h b/include/libcamera/internal/ipa_manager.h index aaa3ca37c..7ab193112 100644 --- a/include/libcamera/internal/ipa_manager.h +++ b/include/libcamera/internal/ipa_manager.h @@ -34,10 +34,10 @@ public: ~IPAManager(); template - std::unique_ptr createIPA(PipelineHandler *pipe, uint32_t minVersion, + std::unique_ptr createIPA(const char *name, uint32_t minVersion, uint32_t maxVersion) { - IPAModule *m = module(pipe, minVersion, maxVersion); + IPAModule *m = module(name, minVersion, maxVersion); if (!m) return nullptr; @@ -68,7 +68,7 @@ private: std::vector &files); unsigned int addDir(const char *libDir, unsigned int maxDepth = 0); - IPAModule *module(PipelineHandler *pipe, uint32_t minVersion, + IPAModule *module(const char *name, uint32_t minVersion, uint32_t maxVersion); bool isSignatureValid(IPAModule *ipa) const; diff --git a/include/libcamera/internal/ipa_module.h b/include/libcamera/internal/ipa_module.h index 15f19492c..a0a53764e 100644 --- a/include/libcamera/internal/ipa_module.h +++ b/include/libcamera/internal/ipa_module.h @@ -36,8 +36,8 @@ public: IPAInterface *createInterface(); - bool match(PipelineHandler *pipe, - uint32_t minVersion, uint32_t maxVersion) const; + bool match(const char *name, uint32_t minVersion, + uint32_t maxVersion) const; protected: std::string logPrefix() const override; diff --git a/include/libcamera/internal/pipeline_handler.h b/include/libcamera/internal/pipeline_handler.h index 6922ce18e..b60c07b13 100644 --- a/include/libcamera/internal/pipeline_handler.h +++ b/include/libcamera/internal/pipeline_handler.h @@ -76,7 +76,14 @@ public: std::unique_ptr createIPA(uint32_t minVersion, uint32_t maxVersion) { IPAManager *ipaManager = manager_->_d()->ipaManager(); - return ipaManager->createIPA(this, minVersion, maxVersion); + return ipaManager->createIPA(name_, minVersion, maxVersion); + } + + template + std::unique_ptr createIPA(const char *ipaName, uint32_t minVersion, uint32_t maxVersion) + { + IPAManager *ipaManager = manager_->_d()->ipaManager(); + return ipaManager->createIPA(ipaName, minVersion, maxVersion); } protected: diff --git a/src/libcamera/ipa_manager.cpp b/src/libcamera/ipa_manager.cpp index 41918e4c2..b709a024e 100644 --- a/src/libcamera/ipa_manager.cpp +++ b/src/libcamera/ipa_manager.cpp @@ -248,15 +248,15 @@ unsigned int IPAManager::addDir(const char *libDir, unsigned int maxDepth) /** * \brief Retrieve an IPA module that matches a given pipeline handler - * \param[in] pipe The pipeline handler + * \param[in] name The IPA module string identifier * \param[in] minVersion Minimum acceptable version of IPA module * \param[in] maxVersion Maximum acceptable version of IPA module */ -IPAModule *IPAManager::module(PipelineHandler *pipe, uint32_t minVersion, +IPAModule *IPAManager::module(const char *name, uint32_t minVersion, uint32_t maxVersion) { for (const auto &module : modules_) { - if (module->match(pipe, minVersion, maxVersion)) + if (module->match(name, minVersion, maxVersion)) return module.get(); } @@ -266,7 +266,7 @@ IPAModule *IPAManager::module(PipelineHandler *pipe, uint32_t minVersion, /** * \fn IPAManager::createIPA() * \brief Create an IPA proxy that matches a given pipeline handler - * \param[in] pipe The pipeline handler that wants a matching IPA proxy + * \param[in] name The IPA module name * \param[in] minVersion Minimum acceptable version of IPA module * \param[in] maxVersion Maximum acceptable version of IPA module * diff --git a/src/libcamera/ipa_module.cpp b/src/libcamera/ipa_module.cpp index e6ea61e44..c89887954 100644 --- a/src/libcamera/ipa_module.cpp +++ b/src/libcamera/ipa_module.cpp @@ -462,22 +462,22 @@ IPAInterface *IPAModule::createInterface() } /** - * \brief Verify if the IPA module matches a given pipeline handler - * \param[in] pipe Pipeline handler to match with + * \brief Verify if the IPA module matches a given name + * \param[in] name The IPA module name * \param[in] minVersion Minimum acceptable version of IPA module * \param[in] maxVersion Maximum acceptable version of IPA module * - * This function checks if this IPA module matches the \a pipe pipeline handler, + * This function checks if this IPA module matches the requested \a name * and the input version range. * - * \return True if the pipeline handler matches the IPA module, or false otherwise + * \return True if the IPA module matches, or false otherwise */ -bool IPAModule::match(PipelineHandler *pipe, - uint32_t minVersion, uint32_t maxVersion) const +bool IPAModule::match(const char *name, uint32_t minVersion, + uint32_t maxVersion) const { return info_.pipelineVersion >= minVersion && info_.pipelineVersion <= maxVersion && - !strcmp(info_.pipelineName, pipe->name()); + !strcmp(info_.name, name); } std::string IPAModule::logPrefix() const diff --git a/src/libcamera/pipeline_handler.cpp b/src/libcamera/pipeline_handler.cpp index e7145c1d4..25fc11989 100644 --- a/src/libcamera/pipeline_handler.cpp +++ b/src/libcamera/pipeline_handler.cpp @@ -836,11 +836,32 @@ void PipelineHandler::disconnect() */ /** - * \fn PipelineHandler::createIPA() - * \brief Create an IPA proxy that matches this pipeline handler + * \fn PipelineHandler::createIPA(const char *ipaName, uint32_t minVersion, uint32_t maxVersion) + * \brief Create an IPA proxy that matches the requested name and version + * \param[in] ipaName The IPA module name * \param[in] minVersion Minimum acceptable version of IPA module * \param[in] maxVersion Maximum acceptable version of IPA module * + * Create an IPA module using \a ipaName as the matching identifier. This + * overload allows pipeline handlers to create an IPA module by specifying its + * name instead of relying on the fact that the IPA module matches the pipeline + * handler's one. + * + * \return A newly created IPA proxy, or nullptr if no matching IPA module is + * found or if the IPA proxy fails to initialize + */ + +/** + * \fn PipelineHandler::createIPA(uint32_t minVersion, uint32_t maxVersion) + * \brief Create an IPA proxy that matches the pipeline handler name and the + * requested version + * \param[in] minVersion Minimum acceptable version of IPA module + * \param[in] maxVersion Maximum acceptable version of IPA module + * + * Create an IPA module using the pipeline handler name as the matching + * identifier. This overload allows pipeline handler to create an IPA module + * whose name matches the pipeline handler one. + * * \return A newly created IPA proxy, or nullptr if no matching IPA module is * found or if the IPA proxy fails to initialize */ From patchwork Tue May 12 17:53:38 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Hans de Goede X-Patchwork-Id: 26744 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 59565BDB1C for ; Tue, 12 May 2026 17:53:54 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 0B7FB63030; Tue, 12 May 2026 19:53:54 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=qualcomm.com header.i=@qualcomm.com header.b="CTV+kVZW"; dkim=pass (2048-bit key; unprotected) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="hpdBGSWZ"; dkim-atps=neutral Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 10A7A6302B for ; Tue, 12 May 2026 19:53:50 +0200 (CEST) Received: from pps.filterd (m0279866.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 64CC4TdW3320988 for ; Tue, 12 May 2026 17:53:49 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s=qcppdkim1; bh= MVhSLAevAIMMhWm3lhl373TWZa4csmk+fZHG60DydbA=; b=CTV+kVZWXDFnAWvU 2Y9FesEXwl7Z/6y/Ald1sdnqE0QX8MvmEXYNmPdeJOxq54prCyTpfU1pVoO3ZmPA Kk6NckKPcXGSkysybD/3DF8FNfe7rE6/b4GXyGcwUC1FVaT4d3LYB/vDMskRapcb iYungUme89AYmyyLCKNs5/ljOY2mSWWZLs6h5+gfJfQiHYkSp9y4zlq8LxqOOSh4 tJilIIC3fcgDCXUrC1AUlHQpaKUZ+QcSRlWwJMgaeLWQj0BaDq408OVE5wZLupxv g55kuebAbcZdZ9EByCPXsfE5TzRDqvF4DbLmdjDBDY+Pc4opwTZlpJaVARgJFDwU i7ILYw== Received: from mail-ua1-f71.google.com (mail-ua1-f71.google.com [209.85.222.71]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4e43w1sbv6-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Tue, 12 May 2026 17:53:48 +0000 (GMT) Received: by mail-ua1-f71.google.com with SMTP id a1e0cc1a2514c-95cf2f6a8d6so9962244241.1 for ; Tue, 12 May 2026 10:53:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1778608427; x=1779213227; darn=lists.libcamera.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=MVhSLAevAIMMhWm3lhl373TWZa4csmk+fZHG60DydbA=; b=hpdBGSWZLYFaW69YKVh8uGmKDMtzNvCg89hacK4JmxGBYI3DYaWUyNtQ1LaBx5xNE9 OOoncu6HS28PIt5R+1BdUflRuqzoizCEK36WElgPiJO8QBm806nDfoJriYu6EEVgIHEZ 9rrT/NEl/U71HcnOfGTeu0NbLvQAJl6WYndIJjqRDq6VzTKwp3w3iRwySV83/kPt95jk 3MJlr2J2uzdFgmtP/P+tbtA5kvYGHxsVpocdQnIf38m73PBZSrsuTrAg82w0zLQkBlno r7PpR1a4cTuddn+yjI7zSboWq9ig6Ps5J3C74Af+2tY1HPx5OXacZ8zLvijtOnY8wv5Z XqYw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778608427; x=1779213227; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=MVhSLAevAIMMhWm3lhl373TWZa4csmk+fZHG60DydbA=; b=ONlJoszk5Cyr6fqKYSZHnfd1jNER/qacwCyqnGSFAxS3/CceR8UIlhQm1U7A9pywRj mXLuo5ui9P6v+VVi9UPCFq5oAmYB1+KxSnInuUgZEwMK7P4ImF0j9LbKK2r1C5yZyhII eQY1TOyS8RJ9LJOK8lP1ZUIB+eBnIDDi08JdNDDFOFwfUfuymf2WqTxLj9FMW46b3GC0 jaSw45fEGpRSObXYGcSRxH7MP4lmlWzOHR6gBaf+vXbprDaeu78RI+BmNm0Dk8mJZPEa WUxqyjXimxPQHyoL24uOo8gLxW3KGCmAOhIHj68coVsK0ChHBpEEOWqh6IKust5NCStx nQxg== X-Gm-Message-State: AOJu0YyMX3wMmvDvkyEPD6qqqzdmij0Me5ObKbLlKegZtmySqG5Gu34A Hov5SlUoNoz4mlUa4JwIco6WRxnKuWp1OWz9TL8FuY36Ah8saYSEwiPtU0h7kH4WviK8YRIpqJx GM20cakupS6MrY52/lTMvwLrYYzkuDKvIDXAlC94syrWZz/W4M9EyjmjN4w3M9yp2hy5PfsTB4m Yax6WW4zwo X-Gm-Gg: Acq92OGWFvO40M/BgGjWaxSl3TCL4l8k5vhV/kEdyffpFGHKyL8+DYvTqsDwvQbXGoQ qSK0rBmaxLn2B/A2moIl7YdZ71eZ/sNPq64hH/TKN+iDtM9ct2tDv3LF5qMm3twyvEqVUif9CKi 8lSYIyUSF8UrBfuGV5t3lTM8gwT7NfsB6keDgeRUDVLJ/f74LZ6DT/MWbGC6XpnrO5GMEhJT2a0 hz4mcaJbCQWlQN2rdKAgLCKRJl0ntq+N6rY4Ty3HgdHZTezP3B+YEc2tKyiHn/rU+W4gOnJpOa8 8e6SXjoXdUu54FBPngCThSd5jvkNoKQPVk8/m0EUrfQs1lnBVY/5vce0yz78BxRwpaI5Sx0tAGW K6KLVduRj1lC/j5DMciZV/8Ue1HWEhAOaduYcoi1uipnaHvGZBkn8tg7zbeRSX0RAOrPc8lCRbK F6t5QvhmvCH4f+Ri7lw6L5IuxwFk+tNq8JKHvd X-Received: by 2002:a05:6102:5e91:b0:600:3b3e:681a with SMTP id ada2fe7eead31-635d14761e2mr2039702137.14.1778608427417; Tue, 12 May 2026 10:53:47 -0700 (PDT) X-Received: by 2002:a05:6102:5e91:b0:600:3b3e:681a with SMTP id ada2fe7eead31-635d14761e2mr2039693137.14.1778608426964; Tue, 12 May 2026 10:53:46 -0700 (PDT) Received: from shalem (2001-1c00-0c32-7800-5bfa-a036-83f0-f9ec.cable.dynamic.v6.ziggo.nl. [2001:1c00:c32:7800:5bfa:a036:83f0:f9ec]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-bce128529fbsm463191566b.36.2026.05.12.10.53.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 May 2026 10:53:45 -0700 (PDT) From: Hans de Goede To: libcamera-devel@lists.libcamera.org Cc: Hans de Goede , Jacopo Mondi , =?utf-8?q?Barnab=C3=A1s_P=C5=91cze?= , Kieran Bingham Subject: [PATCH v5 2/4] ipa: ipa_module: Remove pipelineName Date: Tue, 12 May 2026 19:53:38 +0200 Message-ID: <20260512175340.115153-3-johannes.goede@oss.qualcomm.com> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260512175340.115153-1-johannes.goede@oss.qualcomm.com> References: <20260512175340.115153-1-johannes.goede@oss.qualcomm.com> MIME-Version: 1.0 X-Proofpoint-GUID: U0-Chs6DPvcUUroTybki79JH6dqgJaJE X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNTEyMDE4NSBTYWx0ZWRfX8dHxfpcFuNF+ 1gdzIlqe9fd1oiWLFAVIQVrsxGakDilBjKXOzyLEQxGKoOlyfeCoojVop4pnr3NHztnWYoUQw7w UXHNAWpC8QkqBesMmPlv3JvjdVmZpRmlI67EH1pDdTOB7A0pxR3fU44WfwG+w2+yPstqqC53+Nl ABcUfVMKfZ2oeVCH5NJpe4L/Vkiqe2v0ZkPLUu6ZgH3cVk6h5V7/tNQyvqZ1fpqI/eUKAm+hGBF sxoY5nio600ivpSQ3svB1Ca3zYZIS4wSz5Q3a+BOtG9zvzzLdyx1gNd0BqLRcXU7jIvPq1uMx5s 1pqS/aGnujuocnXUp6Y1BTbVKP8kox0Dyqa/kJRG9B2VIBWLpO30hQdev9uTA0838qGUKTLuoKL teh599MMRO/DRpqYztzNasZCh+8NkVXbaGTfgymVGqeVe0FgWalsqIUUw3m7P592B7S0ZjuXJWu XoSVkvLfVPKQ3+gDgvA== X-Proofpoint-ORIG-GUID: U0-Chs6DPvcUUroTybki79JH6dqgJaJE X-Authority-Analysis: v=2.4 cv=BoGtB4X5 c=1 sm=1 tr=0 ts=6a03692c cx=c_pps a=KB4UBwrhAZV1kjiGHFQexw==:117 a=xqWC_Br6kY4A:10 a=IkcTkHD0fZMA:10 a=NGcC8JguVDcA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=YMgV9FUhrdKAYTUUvYB2:22 a=P1BnusSwAAAA:8 a=EUspDBNiAAAA:8 a=lvZftHTMWe99GEGio_gA:9 a=3ZKOabzyN94A:10 a=QEXdDO2ut3YA:10 a=o1xkdb1NAhiiM49bd1HK:22 a=D0XLA9XvdZm18NrgonBM:22 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293, Aquarius:18.0.1143, Hydra:6.1.51, FMLib:17.12.100.49 definitions=2026-05-11_05,2026-05-08_02,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 lowpriorityscore=0 bulkscore=0 adultscore=0 clxscore=1015 impostorscore=0 phishscore=0 spamscore=0 suspectscore=0 malwarescore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2605050000 definitions=main-2605120185 X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" From: Jacopo Mondi All the IPA modules declare a pipelineName that is identical to their name. As we now support creating IPAs by name (either explicitly provided by the pipeline handlers or by using the pipeline name), the duplicated information in IPAModuleInfo is redundant. Remove it. Signed-off-by: Jacopo Mondi Reviewed-by: Barnabás Pőcze Reviewed-by: Kieran Bingham Reviewed-by: Hans de Goede Signed-off-by: Hans de Goede --- include/libcamera/ipa/ipa_module_info.h | 1 - src/ipa/ipu3/ipu3.cpp | 1 - src/ipa/mali-c55/mali-c55.cpp | 1 - src/ipa/rkisp1/rkisp1.cpp | 1 - src/ipa/rpi/pisp/pisp.cpp | 1 - src/ipa/rpi/vc4/vc4.cpp | 1 - src/ipa/simple/soft_simple.cpp | 1 - src/ipa/vimc/vimc.cpp | 1 - src/libcamera/ipa_module.cpp | 15 ++++++--------- test/ipa/ipa_module_test.cpp | 3 --- 10 files changed, 6 insertions(+), 20 deletions(-) diff --git a/include/libcamera/ipa/ipa_module_info.h b/include/libcamera/ipa/ipa_module_info.h index 3507a6d76..436ec82d7 100644 --- a/include/libcamera/ipa/ipa_module_info.h +++ b/include/libcamera/ipa/ipa_module_info.h @@ -16,7 +16,6 @@ namespace libcamera { struct IPAModuleInfo { int moduleAPIVersion; uint32_t pipelineVersion; - char pipelineName[256]; char name[256]; } __attribute__((packed)); diff --git a/src/ipa/ipu3/ipu3.cpp b/src/ipa/ipu3/ipu3.cpp index 4bdc4b767..42d475ecc 100644 --- a/src/ipa/ipu3/ipu3.cpp +++ b/src/ipa/ipu3/ipu3.cpp @@ -672,7 +672,6 @@ const struct IPAModuleInfo ipaModuleInfo = { IPA_MODULE_API_VERSION, 1, "ipu3", - "ipu3", }; /** diff --git a/src/ipa/mali-c55/mali-c55.cpp b/src/ipa/mali-c55/mali-c55.cpp index 1d3af0627..47bcd3748 100644 --- a/src/ipa/mali-c55/mali-c55.cpp +++ b/src/ipa/mali-c55/mali-c55.cpp @@ -380,7 +380,6 @@ const struct IPAModuleInfo ipaModuleInfo = { IPA_MODULE_API_VERSION, 1, "mali-c55", - "mali-c55", }; IPAInterface *ipaCreate() diff --git a/src/ipa/rkisp1/rkisp1.cpp b/src/ipa/rkisp1/rkisp1.cpp index 58ef163d8..e0dde542c 100644 --- a/src/ipa/rkisp1/rkisp1.cpp +++ b/src/ipa/rkisp1/rkisp1.cpp @@ -481,7 +481,6 @@ const struct IPAModuleInfo ipaModuleInfo = { IPA_MODULE_API_VERSION, 1, "rkisp1", - "rkisp1", }; IPAInterface *ipaCreate() diff --git a/src/ipa/rpi/pisp/pisp.cpp b/src/ipa/rpi/pisp/pisp.cpp index de2a6afeb..975d8bfdf 100644 --- a/src/ipa/rpi/pisp/pisp.cpp +++ b/src/ipa/rpi/pisp/pisp.cpp @@ -1145,7 +1145,6 @@ const IPAModuleInfo ipaModuleInfo = { IPA_MODULE_API_VERSION, 1, "rpi/pisp", - "rpi/pisp", }; IPAInterface *ipaCreate() diff --git a/src/ipa/rpi/vc4/vc4.cpp b/src/ipa/rpi/vc4/vc4.cpp index b6ca44e7a..f30eee7ff 100644 --- a/src/ipa/rpi/vc4/vc4.cpp +++ b/src/ipa/rpi/vc4/vc4.cpp @@ -633,7 +633,6 @@ const struct IPAModuleInfo ipaModuleInfo = { IPA_MODULE_API_VERSION, 1, "rpi/vc4", - "rpi/vc4", }; IPAInterface *ipaCreate() diff --git a/src/ipa/simple/soft_simple.cpp b/src/ipa/simple/soft_simple.cpp index 629e1a32d..d4ab91e30 100644 --- a/src/ipa/simple/soft_simple.cpp +++ b/src/ipa/simple/soft_simple.cpp @@ -343,7 +343,6 @@ const struct IPAModuleInfo ipaModuleInfo = { IPA_MODULE_API_VERSION, 0, "simple", - "simple", }; IPAInterface *ipaCreate() diff --git a/src/ipa/vimc/vimc.cpp b/src/ipa/vimc/vimc.cpp index 4162b848f..bae48ea90 100644 --- a/src/ipa/vimc/vimc.cpp +++ b/src/ipa/vimc/vimc.cpp @@ -183,7 +183,6 @@ const struct IPAModuleInfo ipaModuleInfo = { IPA_MODULE_API_VERSION, 0, "vimc", - "vimc", }; IPAInterface *ipaCreate() diff --git a/src/libcamera/ipa_module.cpp b/src/libcamera/ipa_module.cpp index c89887954..7340853ea 100644 --- a/src/libcamera/ipa_module.cpp +++ b/src/libcamera/ipa_module.cpp @@ -215,18 +215,15 @@ Span elfLoadSymbol(Span elf, const char *symbol) * \var IPAModuleInfo::pipelineVersion * \brief The pipeline handler version that the IPA module is for * - * \var IPAModuleInfo::pipelineName - * \brief The name of the pipeline handler that the IPA module is for - * - * This name is used to match a pipeline handler with the module. - * * \var IPAModuleInfo::name * \brief The name of the IPA module * - * The name may be used to build file system paths to IPA-specific resources. - * It shall only contain printable characters, and may not contain '*', '?' or - * '\'. For IPA modules included in libcamera, it shall match the directory of - * the IPA module in the source tree. + * This name is used to match a the IPA module. + * + * The name may also be used to build file system paths to IPA-specific + * resources. It shall only contain printable characters, and may not contain + * '*', '?' or '\'. For IPA modules included in libcamera, it shall match the + * directory of the IPA module in the source tree. * * \todo Allow user to choose to isolate open source IPAs */ diff --git a/test/ipa/ipa_module_test.cpp b/test/ipa/ipa_module_test.cpp index 1c97da324..af71c3285 100644 --- a/test/ipa/ipa_module_test.cpp +++ b/test/ipa/ipa_module_test.cpp @@ -37,12 +37,10 @@ protected: cerr << "IPA module information mismatch: expected:" << endl << "moduleAPIVersion = " << testInfo.moduleAPIVersion << endl << "pipelineVersion = " << testInfo.pipelineVersion << endl - << "pipelineName = " << testInfo.pipelineName << endl << "name = " << testInfo.name << "got: " << endl << "moduleAPIVersion = " << info.moduleAPIVersion << endl << "pipelineVersion = " << info.pipelineVersion << endl - << "pipelineName = " << info.pipelineName << endl << "name = " << info.name << endl; } @@ -58,7 +56,6 @@ protected: IPA_MODULE_API_VERSION, 0, "vimc", - "vimc", }; count += runTest("src/ipa/vimc/ipa_vimc.so", testInfo); From patchwork Tue May 12 17:53:39 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans de Goede X-Patchwork-Id: 26745 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id D527AC32F7 for ; Tue, 12 May 2026 17:53:55 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id EA61F63022; Tue, 12 May 2026 19:53:54 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=qualcomm.com header.i=@qualcomm.com header.b="iVo+o7o6"; dkim=pass (2048-bit key; unprotected) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="G7sdFWb4"; dkim-atps=neutral Received: from mx0b-0031df01.pphosted.com (mx0b-0031df01.pphosted.com [205.220.180.131]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 7F3186302E for ; Tue, 12 May 2026 19:53:51 +0200 (CEST) Received: from pps.filterd (m0279872.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 64CHYAaO591816 for ; Tue, 12 May 2026 17:53:50 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:date:from:in-reply-to:message-id :mime-version:references:subject:to; s=qcppdkim1; bh=ZNIDbrZMOBp ukyyc/EOPT+Y55mvet/Oi0tiQabloDNY=; b=iVo+o7o6QI00SbQEms93szQ5/Tk wVYwHI1CS8JzG1tt4ZQGCBs6+1fM5QXiVp5rcOAOFBj2SaMYmx3GFtsdSiIpIX2C B+y8QF8GvlRTAYL5+oMUBqVbW//ZUf7humjdKbzvLSGJFEx4Rhg59u4hnIGQbiSA zPMZcSHFIvWe5580xTYNcLq6kP9SvG9gTF8ig59GmwxALtSBbNUKexGcR93f6GDi Uo1DtJq0wymwINbkMtbWqQ63npNYAEf9T14MXxoPU3BloqS6r084o9vyo/eOOHZT WldswaP7CAse0VFDVD+Funbg4N2Ky1wNER7mA1D0RMaQczqV94jTnnfoOeg== Received: from mail-vs1-f69.google.com (mail-vs1-f69.google.com [209.85.217.69]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4e4319sqy8-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Tue, 12 May 2026 17:53:50 +0000 (GMT) Received: by mail-vs1-f69.google.com with SMTP id ada2fe7eead31-6312af70ad0so5405688137.1 for ; Tue, 12 May 2026 10:53:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1778608429; x=1779213229; darn=lists.libcamera.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=ZNIDbrZMOBpukyyc/EOPT+Y55mvet/Oi0tiQabloDNY=; b=G7sdFWb4ZrzsaqvMyj6RhbaqYcxtMitksGhFKbfe/E9b/JYbkXWJE6ugBOTbUqHhPy UWaSzqIrlIhix7lW38Jw4RuF1cx05VRS2Vy6IBQhf7hV6pO/MUMbbfS5mzl3sMQM6vUC r4/H4aSvtSLOXXhGz3xOY8v7w893N5Ky39x2Vs8gmEcKqlmfo1mJDb4flY4bx61Q2uj6 OtIa0v9BUO5dOmXTpKDGBjxiTBwJelrCk2acG/7sZmF7OFoNVWHdTv+kPXl6JPhg3IET Q6lyDdcJfhky67T3S/hEsyPezxr9VoMVlfBE17LEPq2t4tdxZzDKWjWGTKOwCWmlGp1d kscQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778608429; x=1779213229; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=ZNIDbrZMOBpukyyc/EOPT+Y55mvet/Oi0tiQabloDNY=; b=sr6/oLMvyH882ZaWEsdMNuBCJN5zod22G5rqi6L3z3LW8Il5FMJP2yoBNiALxKbypW YVQ+CA3H6UCh6qKmaNwGMjunPEQuhe5E/ZfWCFp743M443j2rj/o8i7UJ9NeiccJV/Ec eGlDFK9hEPk+j2XX17jiJ/spflll8TpkKTD0fQrZhAytnN5yPDn7baCTT+y4B0kKMF07 1ppZrerTIEyJtCURQkaANzW1I6n1/IztjtvX8fcLReSIEgCsjJm2VB/NO4x8AWtSki/5 HUIlihb5MJZjL2zgBXoO4NswUijN+hGq6OTWzLzJ9MbnePe4gc16mP9c2a9jwyLDOb+b hQ6w== X-Gm-Message-State: AOJu0Yye/8m81ryv+7OpKk3n37WJ2PbqIJxIQpZ03K3WLV0xJIHFu6qM 5nlRoyxUDcPNeBobveX1i8Sbt0oswzN8x0jLAtBm7V6zHSQWa5/ooYWXdgT6sYPoAKTW3fWkECn IN6UQaiofyXHm9ngVijBK8le0moqXPpI6IdglWUSRUW4muutcUCRMZdFK2JzB9J/wGCCPdWh1L5 BIhlQwPKGe X-Gm-Gg: Acq92OEtjweVwqWl63KPrVastn7i34ChhaU8r0H72+m+YbNaKWGfmrkK3JRPNvJ+ew1 CVHpC6sCQKKtSvZ7sG6UDpvkCi0PsYQoGXXRFQSBcH2YBMazkFHzbBtpUE5WocRbvUQvBFfxYfc tEKzyn7x2KEqVYrfbuL46oAdP3gVNoQ+Th01elIej6WWDIuiOOMqkt/82f9jBoeUf+mDbpHNh6B 78R0+q2HW/ycPglyKgqSnwV+aTy2bkqYj4WRHomT7gIGMgrWLCkbDe6TBdMpeDOY1TLORK4iIMX Obt+B2vjV0oUbl8Vj6K0mMTQV6x0luAXosPM2mGfw9UHsf6m7MCK/5L87ZRVbe7beojx86QnwNx Xj5kcAzqHnsdKpGmSb0rSIcOahlJoxHFw1TD9jPunM9KnjIaFYRWK5cSAwJuf6yoOKNCyoiOWvU blxUaPS8elz1zy7vwxbM9QUYDeT1ovDz6uxudK X-Received: by 2002:a05:6102:f9f:b0:631:ab8b:c348 with SMTP id ada2fe7eead31-63615516eb5mr2422057137.8.1778608429344; Tue, 12 May 2026 10:53:49 -0700 (PDT) X-Received: by 2002:a05:6102:f9f:b0:631:ab8b:c348 with SMTP id ada2fe7eead31-63615516eb5mr2422043137.8.1778608428842; Tue, 12 May 2026 10:53:48 -0700 (PDT) Received: from shalem (2001-1c00-0c32-7800-5bfa-a036-83f0-f9ec.cable.dynamic.v6.ziggo.nl. [2001:1c00:c32:7800:5bfa:a036:83f0:f9ec]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-bce128529fbsm463191566b.36.2026.05.12.10.53.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 May 2026 10:53:47 -0700 (PDT) From: Hans de Goede To: libcamera-devel@lists.libcamera.org Cc: Hans de Goede , Jacopo Mondi Subject: [PATCH v5 3/4] ipa: Allow pipelines to have differently named IPA Date: Tue, 12 May 2026 19:53:39 +0200 Message-ID: <20260512175340.115153-4-johannes.goede@oss.qualcomm.com> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260512175340.115153-1-johannes.goede@oss.qualcomm.com> References: <20260512175340.115153-1-johannes.goede@oss.qualcomm.com> MIME-Version: 1.0 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNTEyMDE4NSBTYWx0ZWRfX7gfQmDxopSNZ qu/CDslubiJ8Vo2z8EmfzWZ/TBTt9Y/ltp2T2Dgu4PyznKzuSD/j8fA14C0anaoWVxf8cpNncM3 0KbAJ6nwB8oENKmgzF3fVLypvt8/Wmn9TCJAf5KUoD8qlxGR8a4+34nhNBa9dzTiv9bPsbSswJl 8jlU15GgruPSD32Id0K16E1sp9EU9wC7B0Zsl8iKRg+uEP6xt5zDQq3MUWQJdshl9C1Vr2TCttK Gp3hIWbLskRdSv8O90hHU1SLXUGPM+lIjQcWMv7Oc20MseXhWbCiffgd1YMKv4vEugcLxl+5t0a 92AcjfTYxf+SK1Ob9saTbIcubIlCZo5pSGyYlDWrMjE7hg8BDx9IVIOQamz1bG4kH0of6ROyFfl xneObmCE4dwb3jZNk+lBIcN/1uCpEzYro7tgZfWvR5D4WIqiJ+pOUfJxMGczZJJoJk0s54mknw2 yBJUEI9whagYCUvEopQ== X-Proofpoint-GUID: OSexeiUJso_nYIuJ8F8Hvb7l0aaskYXL X-Authority-Analysis: v=2.4 cv=bp98wkai c=1 sm=1 tr=0 ts=6a03692e cx=c_pps a=5HAIKLe1ejAbszaTRHs9Ug==:117 a=xqWC_Br6kY4A:10 a=NGcC8JguVDcA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=yx91gb_oNiZeI1HMLzn7:22 a=P1BnusSwAAAA:8 a=EUspDBNiAAAA:8 a=c6ydndUcIca2Pb-fbGsA:9 a=gYDTvv6II1OnSo0itH1n:22 a=D0XLA9XvdZm18NrgonBM:22 X-Proofpoint-ORIG-GUID: OSexeiUJso_nYIuJ8F8Hvb7l0aaskYXL X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293, Aquarius:18.0.1143, Hydra:6.1.51, FMLib:17.12.100.49 definitions=2026-05-11_05,2026-05-08_02,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 adultscore=0 clxscore=1015 bulkscore=0 malwarescore=0 lowpriorityscore=0 suspectscore=0 phishscore=0 spamscore=0 impostorscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2605050000 definitions=main-2605120185 X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" From: Jacopo Mondi Right now the build system assumes a 1-to-1 matching between a pipeline handler name and an IPA module. This, as also acknowledged by a \todo comment, is quite a rigid requirement and only allows a 1-to-1 matching between pipeline and IPA names. The more platforms libcamera supports, the more it is likely that a pipeline handler could re-use an IPA module. This is particularly relevant for the softISP IPA module which could theoretically be plugged to any pipeline. Likewise, the forthcoming R-Car Gen4 support uses the RkISP1 IPA and at the moment would require building the 'rkisp1' pipeline in to have the IPA module available. When building IPAs, the build system iterates the list of enabled pipeline handlers and for each of them tries to verify if the 'ipas' list contains a corresponding entry for it. The 'ipas' meson options is an array option and, as no default value is specified for it, it contains by default all its possible choices. In this way if no value is specified for the 'ipas' option, compiling the pipeline handlers ['X','Y', 'Z'] will compile the ['X', 'Y', 'Z'] IPAs. If instead the user specifies '-Dipas=X' during the configuration then only IPA module ['X'] will be built, regardless of which pipeline is enabled. Building an IPA module will anyway require to build a corresponding pipeline with the same name. Relax the 1-to-1 'pipeline'-'IPA' naming requirement by introducing a dictionary that associates pipelines with IPA modules. For each enabled pipeline: 1) Make sure an IPA module exists for it 2) Make sure the IPA module is enabled by the 'ipas' option 3) Make sure the IPA is compiled once only This will require every new pipeline to add an entry to the dictionary and specify which IPA module they would like to use. Signed-off-by: Jacopo Mondi Reviewed-by: Hans de Goede Signed-off-by: Hans de Goede --- src/ipa/meson.build | 40 ++++++++++++++++++++++++++++++---------- 1 file changed, 30 insertions(+), 10 deletions(-) diff --git a/src/ipa/meson.build b/src/ipa/meson.build index eb7846e47..c583c7efd 100644 --- a/src/ipa/meson.build +++ b/src/ipa/meson.build @@ -24,6 +24,16 @@ subdir('libipa') ipa_sign = files('ipa-sign.sh') +supported_ipas = { + 'ipu3': 'ipu3', + 'mali-c55': 'mali-c55', + 'rkisp1': 'rkisp1', + 'rpi/pisp': 'rpi/pisp', + 'rpi/vc4': 'rpi/vc4', + 'simple': 'simple', + 'vimc': 'vimc' +} + ipa_modules = get_option('ipas') # Tests require the vimc IPA, similar to vimc pipline-handler for their @@ -39,24 +49,34 @@ ipa_names = [] subdirs = [] foreach pipeline : pipelines - # The current implementation expects the IPA module name to match the - # pipeline name. - # \todo Make the IPA naming scheme more flexible. - if not ipa_modules.contains(pipeline) + # Make sure an IPA exists for the pipeline + if not supported_ipas.has_key(pipeline) continue endif - enabled_ipa_names += pipeline + + ipa = supported_ipas.get(pipeline) + + # Only build IPAs specified with '-Dipas' + if not ipa_modules.contains(ipa) + continue + endif + + # If enabled already do not add it twice + if enabled_ipa_names.contains(ipa) + continue + endif + enabled_ipa_names += ipa # Allow multi-level directory structuring for the IPAs if needed. - pipeline = pipeline.split('/')[0] - if pipeline in subdirs + ipa = ipa.split('/')[0] + if ipa in subdirs continue endif - subdirs += pipeline - subdir(pipeline) + subdirs += ipa + subdir(ipa) - # Don't reuse the pipeline variable below, the subdirectory may have + # Don't reuse the ipa variable below, the subdirectory may have # overwritten it. endforeach From patchwork Tue May 12 17:53:40 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hans de Goede X-Patchwork-Id: 26746 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 65FA1BDB1C for ; Tue, 12 May 2026 17:53:58 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id D622D63039; Tue, 12 May 2026 19:53:57 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=qualcomm.com header.i=@qualcomm.com header.b="iyQZsEJe"; dkim=pass (2048-bit key; unprotected) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="XaXKFTlx"; dkim-atps=neutral Received: from mx0a-0031df01.pphosted.com (mx0a-0031df01.pphosted.com [205.220.168.131]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 9A7A763034 for ; Tue, 12 May 2026 19:53:54 +0200 (CEST) Received: from pps.filterd (m0279865.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 64CEYXlf1733293 for ; Tue, 12 May 2026 17:53:52 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=qualcomm.com; h= cc:content-transfer-encoding:date:from:in-reply-to:message-id :mime-version:references:subject:to; s=qcppdkim1; bh=jKH51nB78QD mQ2mBANLQ7gzrXOFnT0eA8YNHCwQr13o=; b=iyQZsEJedKcDLUotsaSbb1QCFyk V/pDCgLD3VxJ2uOtYqtg/OaIJcKtzLu7fMOrFcjSF4cJRVyq9cjpmVdpkF2t5etq tr46LxriR2DaTu32bpPdxsl29p9WoewIdE5tRebH5oaG+j0kFZaeokXrZfIyfDu4 B+07NvFcktD1RDkMnItyMjlnPc90bItgRkghTfRLG9aWeLNNT22o9JH960lNaT/0 JgMCt6COodp7Dz+X0NuJm9K1Sw8U4XHQt9WxZif4eHUkpkpq0HApBsIGAGTH6Su6 uP/C+nMRPu8OJBI5MUylLB8e7QoXX5Fhfn/rOWYlwRQaubP9evzoQrLN/vA== Received: from mail-vs1-f71.google.com (mail-vs1-f71.google.com [209.85.217.71]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4e463dgt6w-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Tue, 12 May 2026 17:53:51 +0000 (GMT) Received: by mail-vs1-f71.google.com with SMTP id ada2fe7eead31-6332db4182dso2922263137.0 for ; Tue, 12 May 2026 10:53:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1778608431; x=1779213231; darn=lists.libcamera.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=jKH51nB78QDmQ2mBANLQ7gzrXOFnT0eA8YNHCwQr13o=; b=XaXKFTlxJavzgI/LUcCxluLggJQX7Q92Ufq0Z9cbNVMDhr30KbIDHHIdIfLPpbyhO3 mERE9SyHOLMvs6NgD+OpytSs8o7R/Pu4MY9uafFhVvW8i52xfS3qywNkQFvrcvF+ScQW UdoNG4f6uNKWtjiBNHjduQSgWHQ5asuPDNs4QYUnqhNoY9RzGxwtMgh9RvOn80DhSTo9 5J/+R7c7JgvfJlXDtX7fXS2JVXjgXCpTQpXb/8jlDv3wqzQ87gDaKtBZ1Zbw08+K23aA k6KKvVFJklNNNu7Qov/fGHN2AdXwkMlqkVDDsBqA5OYPckH67K+E2fH7IppxT2r6JDdc 1+vA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778608431; x=1779213231; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=jKH51nB78QDmQ2mBANLQ7gzrXOFnT0eA8YNHCwQr13o=; b=JwJGpIMv0bb6SPoKbZPyXqQqcvqBB9HJlZB5ywOtf75frpZqzLnJFVdoYFed/KRLIX 577nkfGYEL0I7DnL9nHh71+qz4VsfZ7+xLmlfDPoUIJCgVnndxp33969oujN8Wma2SdL FaDtmJWT2zJUFKawVztPhdBKljRBUDbSJ31yjNHNcyndSwf1dtS3R0zRUaSlTL2KvYcx 7HpJaGyxBXRGu7y9Sb2pSC5O26CoVGboDew8atu3YZntt87AGxGi+HPAK2mpKIGksmwq KBdl1SLrxUXwxfyiX4/gCPBB4oygKwS72RbCKtzIKEuPLB4JmBBrDGKlMTLRQck8s+qe S50g== X-Gm-Message-State: AOJu0Yzeu/aEvSATVywKNFJOZ+j0NQIiWDxDAxv2NbA8lqOAXmAVLNx6 O12lvsOLOqfuBVeR+BFjiSYhUY052G1qv3a8gef6gY79LqL8K1tktZ8p9XspPcfSWqtJMgGivWG 2HEUkzdauZgpvtuW5aIdFn6Lv8ePbF7A89sm7gJrf+ulsWLntHVDPDVXVrohtbqV1FfimBSO+hX 5uz0Gr5Usk X-Gm-Gg: Acq92OEaldoLaXzz1/KLx4CHpC658sOfdXf27/MvKzZuTHKGqUPD32Q00aBXQInYfWA tLCgU8RYWn1OGNzsG/FUxQwYVTb3wu0CFwZ0B8E/A0SCVRj7AMqB/qpK1oyRupebyzEy0NbOedD 6T6/eiDucJaGtxplUoCybI2xgLyT53IlrhkEGqc3I+70pllPl9EOShRNeJvQg/aC8oFESDjIP2h TsDwSVwkFQGPA5eUwKuqx39otOEdDzGgsXY6xHFULjBO/JRJJjQfuUXgbKw2U+g0Jcfos5QoaRV N5CobpWA1MLySq+/TVxe9G2EhhCNLpzB0faWajtt/WP7w7JK9iufKaMe58QMXxuPZf0LK1I5i9h wXu+EZEr8Ra1xTU9sEDKmjCBSVPfv4izvcI/AiIshVD+A/TWJYiwNFeccItLJCqPU1Ce+NA2nMq BVQ0CsitmZDNc1GUFhdPCIjngQ5YhlV99ZNyaH X-Received: by 2002:a05:6102:2c87:b0:5ff:f4ae:a154 with SMTP id ada2fe7eead31-630f8e78111mr16022885137.1.1778608430783; Tue, 12 May 2026 10:53:50 -0700 (PDT) X-Received: by 2002:a05:6102:2c87:b0:5ff:f4ae:a154 with SMTP id ada2fe7eead31-630f8e78111mr16022874137.1.1778608430332; Tue, 12 May 2026 10:53:50 -0700 (PDT) Received: from shalem (2001-1c00-0c32-7800-5bfa-a036-83f0-f9ec.cable.dynamic.v6.ziggo.nl. [2001:1c00:c32:7800:5bfa:a036:83f0:f9ec]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-bce128529fbsm463191566b.36.2026.05.12.10.53.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 May 2026 10:53:49 -0700 (PDT) From: Hans de Goede To: libcamera-devel@lists.libcamera.org Cc: Hans de Goede Subject: [PATCH v5 4/4] libcamera: software_isp: Explicitly load "simple" IPA Date: Tue, 12 May 2026 19:53:40 +0200 Message-ID: <20260512175340.115153-5-johannes.goede@oss.qualcomm.com> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20260512175340.115153-1-johannes.goede@oss.qualcomm.com> References: <20260512175340.115153-1-johannes.goede@oss.qualcomm.com> MIME-Version: 1.0 X-Proofpoint-GUID: pds8HevnvMHXS19Dg8ittLoF2VU2Hg91 X-Proofpoint-ORIG-GUID: pds8HevnvMHXS19Dg8ittLoF2VU2Hg91 X-Authority-Analysis: v=2.4 cv=aLTAb79m c=1 sm=1 tr=0 ts=6a03692f cx=c_pps a=P2rfLEam3zuxRRdjJWA2cw==:117 a=xqWC_Br6kY4A:10 a=NGcC8JguVDcA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=Um2Pa8k9VHT-vaBCBUpS:22 a=EUspDBNiAAAA:8 a=QNtEkiVxkXohdoMW-wIA:9 a=ODZdjJIeia2B_SHc_B0f:22 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwNTEyMDE4NSBTYWx0ZWRfXx2aObE/yYIWO QzD7X74/TFQZ3i6czF70V6NNMDaLMnclHZ+f8wAtT8T5tEGH++KgN0B7+uX/2YJdjBVzjG5BIF3 7FqobluINuY4gdux4NyhuCAhQO5Vb2n6s0Qpwd4NxTjvfV+soXdvUQlUcVgznL0HzeM19qUCU7x FP+rnmsqu8ra/xwKrHPIrTB96wEiceqsQRqywJZODU01IddxFk3h1pPUW7nL9G4dBOWJIxH/xRJ q1nOTIzJ9Lvsz+/yV6ypaG0u3wFtHo7eHtHvMbHZjLB++I2AXh9TtfDKoDVh09ONvptQVagL4iJ 9Upa+q2gsx4JvwXhKRKmz6r38XxixkFfH95zjAufZYYaKYY7U0lrajmHT5tfX34S3HpTxjCXFlA b4dE9FGWBpms9AcIKpydX8kYHMNIUdcMn9jPQWc7/J9K+jPBExrL+Xt47mLyVUPyxfs+iNqdZk/ ldinEIrZPsjcsnZSpaA== X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293, Aquarius:18.0.1143, Hydra:6.1.51, FMLib:17.12.100.49 definitions=2026-05-11_05,2026-05-08_02,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 spamscore=0 suspectscore=0 adultscore=0 lowpriorityscore=0 phishscore=0 impostorscore=0 bulkscore=0 malwarescore=0 priorityscore=1501 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2605050000 definitions=main-2605120185 X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" Explicitly specify the "simple" IPA name when loading the IPA so that the softISP can be used with other pipeline-handlers too. Signed-off-by: Hans de Goede --- src/libcamera/software_isp/software_isp.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libcamera/software_isp/software_isp.cpp b/src/libcamera/software_isp/software_isp.cpp index 781cf02f8..4f30aa180 100644 --- a/src/libcamera/software_isp/software_isp.cpp +++ b/src/libcamera/software_isp/software_isp.cpp @@ -129,7 +129,7 @@ SoftwareIsp::SoftwareIsp(PipelineHandler *pipe, const CameraSensor *sensor, debayer_->inputBufferReady.connect(this, &SoftwareIsp::inputReady); debayer_->outputBufferReady.connect(this, &SoftwareIsp::outputReady); - ipa_ = pipe->createIPA(0, 0); + ipa_ = pipe->createIPA("simple", 0, 0); if (!ipa_) { LOG(SoftwareIsp, Error) << "Creating IPA for software ISP failed";