From patchwork Wed Aug 12 18:49:05 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: 27760 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 24DD7C3264 for ; Wed, 12 Aug 2026 18:49:24 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id C4F0C682BF; Wed, 12 Aug 2026 20:49:23 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=qualcomm.com header.i=@qualcomm.com header.b="aVKro4uG"; dkim=pass (2048-bit key; unprotected) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="QcLH6WGB"; 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 8F91D682B2 for ; Wed, 12 Aug 2026 20:49:20 +0200 (CEST) Received: from pps.filterd (m0279873.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 67CI8jjC355329 for ; Wed, 12 Aug 2026 18:49:19 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= LpVaJ8XyDdY3Z4NU4YyIFIuQGALht3poswTPE/FwpFY=; b=aVKro4uGQUo5mq5n sBn+BrpqcpS5++tjeCH3CnxbNVM/qh8DwICuUYlKreQSfcVNlTyGPTlq32HGItAf okCoClSKVHWTMt1ZTQdOugh7t8vRJ4KhFKqWBL3Njmy/EUY6QmnuFAXvuGGk4Cpl sgz3joXQ6KQhnxaSiKLb7FDkYlYcGkHFKFagNlsQIZ6eN8X4esA1eobl3+zXs9nD NkKVpF7/jhdJSMN/Ic4xbEC1OkRVIeX46NTWgYVCWbM5V0ZI/PCOfy1URMiBrqB0 DjELqkhmliwvYLf+oe68hUUz8zbWOD44Cs6b+2ynVwrO/ZPkpLWgqTB/Uchdv7sk 470UUw== Received: from mail-qt1-f199.google.com (mail-qt1-f199.google.com [209.85.160.199]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4g0hj2uqtc-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Wed, 12 Aug 2026 18:49:18 +0000 (GMT) Received: by mail-qt1-f199.google.com with SMTP id d75a77b69052e-51c1a97644aso11648251cf.2 for ; Wed, 12 Aug 2026 11:49:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1786560558; x=1787165358; darn=lists.libcamera.org; h=content-transfer-encoding:content-type:mime-version:references :in-reply-to:message-id:date:subject:cc:to:from:from:to:cc:subject :date:message-id:reply-to:content-type; bh=LpVaJ8XyDdY3Z4NU4YyIFIuQGALht3poswTPE/FwpFY=; b=QcLH6WGBKaIlYReD21cOXdwasTK5hxZqMniNDbTBkHxyKiwID6minRilCx/reMF3r9 NoBiZ6EnD/qM4qf2ksglYLtxkl10XCmF+ZZQNT2NBDxq1F2O0Wo5Gqdc+MRjjzpxA5HA BvQ3qXErNi6tAuDS3//fulRxqTkUCo0Bx6UO33b9m4xZTAL0Yev3nzroYRBIRoPNMvTH wDovQStXng5m2lT4W0Q9zb0ed5rhGxeKSjBJCxCcVO9kj1qKDQFL4hvaoFmBD2Izp9F9 YGqjXwJjZ9bCiehDgIEPn3jAhz6c0so6vs0/ddYkF7AYi4Ah+ZYptAKWxvN2fyx4ExjG V04A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1786560558; x=1787165358; h=content-transfer-encoding:content-type: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 :content-type; bh=LpVaJ8XyDdY3Z4NU4YyIFIuQGALht3poswTPE/FwpFY=; b=alelIJBqmMv+YfNmovv6rrdJ3FsHre6LWbDpdSEPR//wQaWRtLMaJXyQoj7ocYJm1r se+4TiLOMAvbWVJFnk7aZzGxtXCyezwcWm6c0YGk/y6VDlu13xPzCYa5EEJWIq0ZJNl7 LI0jHyQ14PiYcm+LhzyO93sXAUV2UMT+PKqFlOM8174J860ipukgiAfIvHoKADsZACQH JKamwZS1d4BpbsTGZP2CWANwUtPiWyz0mkvpu2QZPUKsXGCYxMm4RbbrGIqhJ9lJpZsz U6yaHJC5rrRjDrMOI6O77SN+5ir73q1shOBaarJ1QDg/CsC9mFbhIdqVJR47xHnxBOv7 BApw== X-Gm-Message-State: AOJu0YxT9pwwzwUX81TnYPRz4JhlWZrcgSUlzmtnrBEALs60GqxQzUGP lzewZODyegItaCIFWgeAQcxHrX358Kiaj7rh1Kwxv3qTzRa+29qQWveDRavy70nJ8gYMXXPS8iL U5QXLlV5X+cT9gXUhnSN3BjqHoXN7b8BfGG6wwFJL2eP58Ezi1if8XeopOD2KmE2WIhLo6Thj6V 6xxubEmJns X-Gm-Gg: AR+sD13/HMwrB7unx318GLx0iPCHest17c2Z4iDY+xoA5/bu7U8QuQ8rtqBX8+GlVfA rnfLck66rQg+5NlDNZZeGqerUxC24ZbuVRkI04caVGvNWZpw7j7XXPYGtnDFYi9qU1+GUTCF135 Y1ZvmHcCb6phWMdriUFrMUNAQnWNZZP4rC3lIOZ0fjfvNxJTD0yDh8OdYGTlaLc88vZw+VzNmLm 107ij9Cp17NqmPHPymEEyHKCzs3xsjoNalyT3ubEagrK5EZCSUCzAEk6FIDBJDsa37UIbMQ4/If ZAufRlF4E2XUCPzcSJSjloCpCyieaWMHi8BRLusEvW7IGygIxhOFAmG4ejiUqia9Z6ihHbR10Ix 3wgup/C+EUMEE0Cckcwom5WdOnihMfb/wjexd3WeirkuHBNdkjv6ag24iyqgt21PJ1Z1cK6HO4N gMDmJMrAS64EileE0= X-Received: by 2002:ac8:5a15:0:b0:51c:1a4c:3c9f with SMTP id d75a77b69052e-52d73bf01aamr3023961cf.4.1786560558107; Wed, 12 Aug 2026 11:49:18 -0700 (PDT) X-Received: by 2002:ac8:5a15:0:b0:51c:1a4c:3c9f with SMTP id d75a77b69052e-52d73bf01aamr3023371cf.4.1786560557493; Wed, 12 Aug 2026 11:49:17 -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 4fb4d7f45d1cf-6a37f8a202fsm52348a12.15.2026.08.12.11.49.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 12 Aug 2026 11:49:15 -0700 (PDT) From: Hans de Goede To: libcamera-devel@lists.libcamera.org Cc: Loic Poulain , Hans de Goede , Kieran Bingham , =?utf-8?q?Niklas_S=C3=B6derlund?= , Jacopo Mondi Subject: [PATCH v7 1/8] libcamera: Create IPA by name Date: Wed, 12 Aug 2026 20:49:05 +0200 Message-ID: <20260812184912.287894-2-johannes.goede@oss.qualcomm.com> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260812184912.287894-1-johannes.goede@oss.qualcomm.com> References: <20260812184912.287894-1-johannes.goede@oss.qualcomm.com> MIME-Version: 1.0 X-Authority-Analysis: v=2.4 cv=a8EAM0SF c=1 sm=1 tr=0 ts=6a7cc02e cx=c_pps a=WeENfcodrlLV9YRTxbY/uA==:117 a=xqWC_Br6kY4A:10 a=IkcTkHD0fZMA:10 a=Sv0fKeRqtYgA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=rJkE3RaqiGZ5pbrm-msn:22 a=P1BnusSwAAAA:8 a=EUspDBNiAAAA:8 a=rl81jYYfPRFGC34jM1YA:9 a=3ZKOabzyN94A:10 a=QEXdDO2ut3YA:10 a=kacYvNCVWA4VmyqE58fU:22 a=D0XLA9XvdZm18NrgonBM:22 X-Proofpoint-ORIG-GUID: BnucEBUNrcjZQaSv5Nx3srxxoj7l6-O6 X-Proofpoint-GUID: BnucEBUNrcjZQaSv5Nx3srxxoj7l6-O6 X-Proofpoint-Spam-Info: AW1haW4tMjYwODEyMDE1MSBTYWx0ZWRfX3CXtj4SBJBbz z5aPIkEidnNOFTRQwCIp+XBhBKgeaKFMoW9AmQk5+aDHpWqP5Pgdh5zt1pQPvll71tQs0nxIKRC qsPTyelcaY/14Li6Li8IEeoCd/1DPzI= X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwODEyMDE1MSBTYWx0ZWRfXxl2gkT5MVB8G +2bCoerWx9xx0tTIIh69zs84VjG3oeGRomRPcaXpb2PNWJoZU2Co4jG4C6u3dIpbPLTFYgjnxuF wsblsnF/bagJYn8STtJHiGDNWMGmeiBuH3VHw81FZQujNdEIDBkSmjOYkqCpita4GObwgE2qkKv PG/CeOt2X1ZaFoNYJTvFj8dmnaN02RT+jMURj4nCvE0a543EuXd0koAapB6Tj47XlyIEZe0Ea2a fcVm2ir/0NToxVEznN4NC0bdAZB7IJEMYPIG8uEmqovOt+wq4XdPblc3ZC1QNgjWur/4IvvGrSV vXhNPk+fG7Jb8S9RDr8P/ZgKDk2hQ3KyCoBmVfCm5ym+cczozfGGfOYZhXIGzuzy6udtvtU0h69 1NLMnVWibQA3EyC16w3IWKjFfOVN1+vjMGWOt1Mz3xHADJwQaFUy3VIWdZmXAtDpZouA+QP2Ulr VneRHJp5/39Dc0+LPkg== X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293, Aquarius:18.0.1176, Hydra:6.1.134, FMLib:17.12.100.49 definitions=2026-08-12_05,2026-08-12_01,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 phishscore=0 suspectscore=0 lowpriorityscore=0 bulkscore=0 impostorscore=0 adultscore=0 spamscore=0 malwarescore=0 clxscore=1015 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2606150000 definitions=main-2608120151 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. Reviewed-by: Kieran Bingham Tested-by: Niklas Söderlund Signed-off-by: Jacopo Mondi 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 +++++++++++++++++-- test/ipa/ipa_interface_test.cpp | 2 +- 7 files changed, 48 insertions(+), 20 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 */ diff --git a/test/ipa/ipa_interface_test.cpp b/test/ipa/ipa_interface_test.cpp index 271c4e2c9..0b01a396e 100644 --- a/test/ipa/ipa_interface_test.cpp +++ b/test/ipa/ipa_interface_test.cpp @@ -99,7 +99,7 @@ protected: EventDispatcher *dispatcher = thread()->eventDispatcher(); Timer timer; - ipa_ = ipaManager_->createIPA(pipe_.get(), 0, 0); + ipa_ = ipaManager_->createIPA(pipe_->name(), 0, 0); if (!ipa_) { cerr << "Failed to create VIMC IPA interface" << endl; return TestFail; From patchwork Wed Aug 12 18:49:06 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: 27761 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 E0D70C3264 for ; Wed, 12 Aug 2026 18:49:26 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 8A617682C5; Wed, 12 Aug 2026 20:49:26 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=qualcomm.com header.i=@qualcomm.com header.b="aUGczqV3"; dkim=pass (2048-bit key; unprotected) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="TK7GtkxW"; 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 AB3BA682B6 for ; Wed, 12 Aug 2026 20:49:22 +0200 (CEST) Received: from pps.filterd (m0279868.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 67CI8mAb277573 for ; Wed, 12 Aug 2026 18:49:21 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= XF4Z5r1ndQnMtmFBq1N2e98ElZtjBKzKDKMicoKapmU=; b=aUGczqV3gZ7NPYC1 QPuGcK+gGRVO92pKoatPRmeWrqWoXTnDMnXe+0AG5C+l7RizQKMDfgrgtVADdncI wSZxjuD+7p8gcd5bLqi7YnV+GoiCkc3XslJ9QRFIhG1vtPVScUR+U1A+ExpklOfq XnPSP74rB3aClZUjE94gtDLu1DHTwQHQmY5zplZIfApycW6F8xfut9X2ZZB2v9kB JYGugWC3trgBoGPypHcp+eF3btJpFtV9v9DE1hwbKym65GKmxiUONACUoguYwcp8 jBeDjsa2d/e0iLlXB+Xay8X8bRsimv1wa9DxEUXrPUqx+RruHmPf45oEYCYzDicy oLCO4w== Received: from mail-qt1-f199.google.com (mail-qt1-f199.google.com [209.85.160.199]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4g0hj1kqb7-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Wed, 12 Aug 2026 18:49:21 +0000 (GMT) Received: by mail-qt1-f199.google.com with SMTP id d75a77b69052e-52ce3c7cb2eso22745141cf.3 for ; Wed, 12 Aug 2026 11:49:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1786560561; x=1787165361; darn=lists.libcamera.org; h=content-transfer-encoding:content-type:mime-version:references :in-reply-to:message-id:date:subject:cc:to:from:from:to:cc:subject :date:message-id:reply-to:content-type; bh=XF4Z5r1ndQnMtmFBq1N2e98ElZtjBKzKDKMicoKapmU=; b=TK7GtkxWHJUNCuOywnKNDgYcGPSFes03G8Rj9qM/n/bwPp/TblUYOQGJOCghQbULuc asXyWxOPsTrU3AJTqC7XU2V55rYs2Bcn6zR89VvtpMDxBLDE95ni+4ALfCNHO6iSof7Y L9p7f4W0Ku7DFAZ0SbdDhE7nfJto3ZtNs7BjUhRprq+qf+LRjNsalLfQKMPpHytSM1Xs boGuDOvXxZ5AnvbN0AYkclTKSlw8ST4X2pI8rKp1vVZitfitwKQA1rMwXA3KxIVbtwYc GlH73eMviyQHVVxgjSCtGdBk6pVCHg+xgUni/aJVpie4INDoF+FOXADhG2vufyEjHciP zQ7Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1786560561; x=1787165361; h=content-transfer-encoding:content-type: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 :content-type; bh=XF4Z5r1ndQnMtmFBq1N2e98ElZtjBKzKDKMicoKapmU=; b=bOB7xGb1uM5VswHtT8XKCCuNSo9aP146ASVngbGbrjZc9/vmemsojvckN+xxB0tjT4 G8F8c3LuVEfnT8qYFlme2WPcKxvKLCNIFXks7FiSWuebGa1ZDxrQUrbb1vDWmp86jvtf AzM13NzQU5nWdVzbHDyb8MvSt6pWkYLsZWVooCBjp7lZ9gFztuYH4XaUhVA9kZXbY8dy aUeeAEdzlBwZ+9aBAEp7xnI57oH3QuA/XQlwpwauRuWoht/I/h4hZS7LYs14ldTIZIll 77P8Mqm4AJPYe6Sg/yfS56+i34lHhKqoEZuE7ZnyCBEAiktYKwpUoU5Vg/dPDVKR0v61 nOhA== X-Gm-Message-State: AOJu0YwLflNGKa1gTRxZUyCyHd4H7yDAPq9FuuszWdyRq91v4gDxrTmw 1YamtZWwogqRFpQsAgpWGKBfF7hFlirdIr2RyzTrxdwo4S70bX4JkkpDiDPFGroMV3hEcUNjKMk M41B9ILKeBIz19OkBA22ea5x/JN4buq4VGtM1WX54enM3j+OgpHydICEoOBTppYMtTNUPc/bxo+ c2AlNzMfGT X-Gm-Gg: AR+sD13EFYXQ4pFozOGoPGObPw+pjuLbqxaR0EW9Mb4fopjE+7EWKIgXOdcvC9M9rIz x882eZS/qxRPNCyKVY3tGm9HbxBxv15s8z3SvKgX/4TA5oQcw2suwzBl3NHcgUT5synDydrg7y8 1GIRiJ9PdaS4iqjCDJkOePUAfRHy/g7534Sm8LevlvI18Bg4kLbMFTCwDq1TPJhbrnUUomBBpeT T5le0W0N7t6U0oDYICdU1REdedzWlV2rJCeQ4Rs4fzQb4UVAzmPMyFV1UmTW8scxGY4w230Vj2a YK18gSzM6sZzRXrMBO+I0d5PXG9nblZYjTSWRh1BmO6Pc0ACX2e/h7geUSRAW+a9MP/InJynm2h ycwy1n54/Xc2gTY++8vy04B6RT4/KtlBTtjt6yIP3NAYa/M/zDkwGE7tYgO1pOykqIjKPspjWO6 6DO0RUofUDmkVr7Yc= X-Received: by 2002:a05:622a:164d:b0:519:5680:1b5 with SMTP id d75a77b69052e-52d73d2af57mr2593241cf.21.1786560560677; Wed, 12 Aug 2026 11:49:20 -0700 (PDT) X-Received: by 2002:a05:622a:164d:b0:519:5680:1b5 with SMTP id d75a77b69052e-52d73d2af57mr2592871cf.21.1786560560251; Wed, 12 Aug 2026 11:49:20 -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 4fb4d7f45d1cf-6a37f8a202fsm52348a12.15.2026.08.12.11.49.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 12 Aug 2026 11:49:18 -0700 (PDT) From: Hans de Goede To: libcamera-devel@lists.libcamera.org Cc: Loic Poulain , Hans de Goede , Jacopo Mondi , =?utf-8?q?Barnab=C3=A1s_P=C5=91cze?= , Kieran Bingham , =?utf-8?q?Niklas_S=C3=B6derlund?= Subject: [PATCH v7 2/8] ipa: ipa_module: Remove pipelineName Date: Wed, 12 Aug 2026 20:49:06 +0200 Message-ID: <20260812184912.287894-3-johannes.goede@oss.qualcomm.com> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260812184912.287894-1-johannes.goede@oss.qualcomm.com> References: <20260812184912.287894-1-johannes.goede@oss.qualcomm.com> MIME-Version: 1.0 X-Proofpoint-ORIG-GUID: fS8oNjnWLngiQ2IHTiFnL1P60VIPySD4 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwODEyMDE1MSBTYWx0ZWRfXwBOrtP5XC5zB j97VbGtrZS7T4kgb0vVWXV2/WTTeApupgIqZv1zdG1IM9ppCrcPLd8nWW1H/fNq0x8e3emMIwkn qPv11lLCsJ6wm//2Puc9vweYIAZUOmaXW3dML/HZoXMNIXJCSqF+0YrUwYnNrxYZQpsJ7IUOAUO K5W2nEK2LRgDhPW4eeVgeYZ8sehhfe56WurDocC8+dvfcNIjI++uDe9tPFemG2TjC7y5iOuWtDb zy+Rb93TBWsqyNZD53qrNDWmwM7XtfgomMOOXu3diuDK56PxWk8PhE91FU+mEtwS4wmqMdjTarE iyrLBJqSxxuwv9xd9LE5lUGPs5dsf0XcHT12DsTfnShfsJxakzB05qGp7CIeVC63BoCdwyKlgG0 bo3bMnAMKpZ5C+mjgfxvq+O30xNFMqkNxGLMrYm9TZoRpYA1DSOd6g8aRFwNFQXEnNqHxzx8AVk U1zoRAs639t6rK5+hSQ== X-Authority-Analysis: v=2.4 cv=K6ES2SWI c=1 sm=1 tr=0 ts=6a7cc031 cx=c_pps a=WeENfcodrlLV9YRTxbY/uA==:117 a=xqWC_Br6kY4A:10 a=IkcTkHD0fZMA:10 a=Sv0fKeRqtYgA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=ZpdpYltYx_vBUK5n70dp:22 a=P1BnusSwAAAA:8 a=EUspDBNiAAAA:8 a=lvZftHTMWe99GEGio_gA:9 a=3ZKOabzyN94A:10 a=QEXdDO2ut3YA:10 a=kacYvNCVWA4VmyqE58fU:22 a=D0XLA9XvdZm18NrgonBM:22 X-Proofpoint-GUID: fS8oNjnWLngiQ2IHTiFnL1P60VIPySD4 X-Proofpoint-Spam-Info: AW1haW4tMjYwODEyMDE1MSBTYWx0ZWRfX9GQf1hRik3Jg bk6qJWvSPR0jirWeky1SNHYMfrt0L6kaAEuJE8BI0E7aQXPhJFFJwHdar9+7qUatutsIKJx9HPK ZDMqCNOJ7WZvYvOJV1MAzZbMDav3+jY= X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293, Aquarius:18.0.1176, Hydra:6.1.134, FMLib:17.12.100.49 definitions=2026-08-12_05,2026-08-12_01,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 suspectscore=0 spamscore=0 adultscore=0 bulkscore=0 impostorscore=0 lowpriorityscore=0 malwarescore=0 clxscore=1015 priorityscore=1501 phishscore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2606150000 definitions=main-2608120151 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. Reviewed-by: Barnabás Pőcze Reviewed-by: Kieran Bingham Reviewed-by: Hans de Goede Tested-by: Niklas Söderlund Signed-off-by: Jacopo Mondi 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 da0dbe4b3..37350eb28 100644 --- a/src/ipa/mali-c55/mali-c55.cpp +++ b/src/ipa/mali-c55/mali-c55.cpp @@ -382,7 +382,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 fd28fc385..88deccfd1 100644 --- a/src/ipa/rpi/pisp/pisp.cpp +++ b/src/ipa/rpi/pisp/pisp.cpp @@ -1147,7 +1147,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..6e8513d0e 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 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 Wed Aug 12 18:49:07 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: 27762 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 59A82C32FE for ; Wed, 12 Aug 2026 18:49:28 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 76F0F682AC; Wed, 12 Aug 2026 20:49:27 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=qualcomm.com header.i=@qualcomm.com header.b="CWaDlec5"; dkim=pass (2048-bit key; unprotected) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="BwWisoWU"; 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 6D4CD682B6 for ; Wed, 12 Aug 2026 20:49:25 +0200 (CEST) Received: from pps.filterd (m0279873.ppops.net [127.0.0.1]) by mx0a-0031df01.pphosted.com (8.18.1.11/8.18.1.11) with ESMTP id 67CI8j0g355332 for ; Wed, 12 Aug 2026 18:49:24 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=EQ1XZRbZGRy B3as4gr3aCKmf2sK+9RMxmTWtjPgyi3Q=; b=CWaDlec5ubW3bowpFQ2tpz2tpTc DEdUGArmVHiVeWOYNlUCLQpwAJx4rDfp15do0NgjLeSxCGoybRC5uVn7g5vXfrWK GOTC/rVeKfc1h+zhRESoAudYMvgpsJl+Bb0rZuRTMbL0J+pCdvbBy61NGBxD8h9x SJzdo1KRoxy+Xhv0L95eMJcNhzJ8WDjk0xofwN7geI4HEF/XA20Uj63SNMjsng4j mcNviTD2nlHw+jNRdZA7XIPNjhHMCHepmj7GwDwtzodM4qjdtWzCfEODJqQTOhGB QzPnJGgDl1E2hI/2nd3WVheaiaCWMRYNBYOvuoaSVeu564ImL2fnHgNPKvA== Received: from mail-qt1-f197.google.com (mail-qt1-f197.google.com [209.85.160.197]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4g0hj2uqtq-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Wed, 12 Aug 2026 18:49:24 +0000 (GMT) Received: by mail-qt1-f197.google.com with SMTP id d75a77b69052e-51bff5c7035so23836551cf.2 for ; Wed, 12 Aug 2026 11:49:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1786560563; x=1787165363; 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:content-type; bh=EQ1XZRbZGRyB3as4gr3aCKmf2sK+9RMxmTWtjPgyi3Q=; b=BwWisoWUmIRVgJ96bH1cs2zlXe/kepWlRAiKnYsxM21tXHUXqz5wkT3DdtN/hhIVhp xxJ7En61/EGcfr9SU4DlHcK4YDyIwXeLqxIMVIKmUJNldWa9Y3NCNSRbOVHlv0FxkRWT xYlhpQRz044aPufRp/8Z4S6ZfnxM4z1LMvAe2/ge17TUsidkgkveVAh8k312P9bN2IoB I4lGgWaTszkVS9kcH6BLgQvMY8Lm3V4WtkTWF88i4bzU7Sx5pyeS4Z7GFUIQwUboFTRl wpaDSbsJ+bBFo11J6KzQgRA7cfmeJ5g5eQAXpz2PJqjTnK4XHcZ8wgSQtJ0br8NCQKA8 +XFg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1786560563; x=1787165363; 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:content-type; bh=EQ1XZRbZGRyB3as4gr3aCKmf2sK+9RMxmTWtjPgyi3Q=; b=Im9iGOp7yrx0e55ybqS7zdjC3AMyzlapgUJPBWwTwFMQeg74VEx4fL9qheyHH5BJwz 33Wpr1k0RoSFFKgauM/u9qv8oEda1h/Yl4N0XQxjxnUIk6Q7Bw6efXfXhV5n9z8c1VQq 5A4Vz3vS0Cvj+o2XuxwMCtUQA+GTA71RDCPLZsBMVJCBwiGs8RR0nPEH8U2lND4XXzRi fFntAFeYcJONVifsarXH6FGeMheulD9JjEJ2BUIdqAVQHZkZVY9wm0iKzPaOxeuvSG9S 1WuXC0L70fMb++B3d1Hry9wKS3e7VHZ6+XAv4krcVzQ4wYy0oKSPTUn+keaAE18wgM5Q Gtvw== X-Gm-Message-State: AOJu0Yyt8QuUBG/QMGYa43lwTfRpkkM1WuUiBdJFQDvs0Z0BXfoM8oVJ /l3p1cGAvKoQ6uxQ46xhEEy6dytKu6ahA3qDV1OSfUpwIaQdw3WsX3soWS5eT8SFOHiWoq4FvRX gqG5s/2NUIYH+RcSyLgBg5SEIzbKJRxEYMvk8vcLHMLjoNsOh0R77VhghJ/LDX+pMMuVrEZ0kyt KD0oX4QgKC X-Gm-Gg: AR+sD12fI+QenRB3FriyIEX4I6jYhBL2b9gHKIHb3KNerxW8nWFUEMYvhIY28Popvfj 6u/OxdJXv9QtQfjL0YgHVbLJDrzqfOwhINPO3jHaJlPjffoLMfJg89m9YgDDcmJx0/+kSpCZ6Si WY25krNinJEbRz/YIZsRjv9BQvLUlzlW8dcxUmuZ3iT+2FTr2D7sqRppRUSKKPTCgSPubVJQNeU WYAl4tAWMF1Kggo97Bkzio8fl6ChSoPgtpPxgPm2BqLsaYfHBWGCITOSBKJayWGa3V+NirIzPuz Ub/jNO2/3rrjFt3GznZZQFw93dROZZQQlGeqwb1KLmm09q95wNdahXQLJAs/ZejH8l9DMzqhAzJ Pdhdvtq04tr5M6h4zzbp6e3jPufOHX5RsZ1pAR1a/pkt37jpObSSVujy/+2lRLu7k8/GqeLK3V6 bT//MKVRFWfIAp8Ww= X-Received: by 2002:a05:622a:513:b0:51a:8dc5:bf89 with SMTP id d75a77b69052e-52d73c381f0mr3407391cf.5.1786560563491; Wed, 12 Aug 2026 11:49:23 -0700 (PDT) X-Received: by 2002:a05:622a:513:b0:51a:8dc5:bf89 with SMTP id d75a77b69052e-52d73c381f0mr3406941cf.5.1786560563009; Wed, 12 Aug 2026 11:49:23 -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 4fb4d7f45d1cf-6a37f8a202fsm52348a12.15.2026.08.12.11.49.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 12 Aug 2026 11:49:21 -0700 (PDT) From: Hans de Goede To: libcamera-devel@lists.libcamera.org Cc: Loic Poulain , Hans de Goede , Jacopo Mondi Subject: [PATCH v7 3/8] ipa: Allow pipelines to have differently named IPA Date: Wed, 12 Aug 2026 20:49:07 +0200 Message-ID: <20260812184912.287894-4-johannes.goede@oss.qualcomm.com> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260812184912.287894-1-johannes.goede@oss.qualcomm.com> References: <20260812184912.287894-1-johannes.goede@oss.qualcomm.com> MIME-Version: 1.0 X-Authority-Analysis: v=2.4 cv=a8EAM0SF c=1 sm=1 tr=0 ts=6a7cc034 cx=c_pps a=EVbN6Ke/fEF3bsl7X48z0g==:117 a=xqWC_Br6kY4A:10 a=Sv0fKeRqtYgA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=rJkE3RaqiGZ5pbrm-msn:22 a=P1BnusSwAAAA:8 a=EUspDBNiAAAA:8 a=c6ydndUcIca2Pb-fbGsA:9 a=a_PwQJl-kcHnX1M80qC6:22 a=D0XLA9XvdZm18NrgonBM:22 X-Proofpoint-ORIG-GUID: 6DE5I7JoRZV6_UT8c-dLLehM-M5ralSU X-Proofpoint-GUID: 6DE5I7JoRZV6_UT8c-dLLehM-M5ralSU X-Proofpoint-Spam-Info: AW1haW4tMjYwODEyMDE1MSBTYWx0ZWRfX6gAJjxGjMpXJ HfczHUNAnLgjDDvnuCXnV5vh6M3eY1U9pGMPQsmSPwRu82ovOLaYytrZXgRMGshhmuMVQPWN0CW 6wG2aJgPJShYPHZt1Zgu0S3JxQskVyo= X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwODEyMDE1MSBTYWx0ZWRfX/ikvFhR0ThvQ UxwIdNgJeXdKEn5m/zMTHE6trM+v6SU/7p7eYrMjw3ZLy6PbueZ7wfnmJnVqu2IqPwCOmjXayqU +rP7jQRbXvVzg/0gWVQsbOlJoGnpugFqLenUWpL3T4zt9ImS4OyHH7S+EUhZwz65NMhVafiFYX/ weDz5MHu0k1mRHWc7y9imwMplm317AnGN/vBBV0A+ZWmGYW+ys1JN840vyeAJQ0mX+LocMLP3nq UpBWWNxBlHT3ryTTaxhJHUGVMNmkwRNQlQY1OEdRi7ltZ/pIB7bk1mNVik20Pq0wPKxt6+LQL63 nlZ3suCvV+b9iJodsLYoqzjLB3t5M9nNnnjWq+G3Fx3cj9Ezs82FECT6YK5loERv65XlCLtRNZy i/8uPqRxwMdb5xDeUkNpC2+eEYVifpN2ABhjZv9F2AVMMpoJgchBKsxpYwi+ygIcW3k2TtiSqpb P/7ph5KOmUBxtDQzkHw== X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293, Aquarius:18.0.1176, Hydra:6.1.134, FMLib:17.12.100.49 definitions=2026-08-12_05,2026-08-12_01,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 phishscore=0 suspectscore=0 lowpriorityscore=0 bulkscore=0 impostorscore=0 adultscore=0 spamscore=0 malwarescore=0 clxscore=1015 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2606150000 definitions=main-2608120151 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. 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. Reviewed-by: Hans de Goede Signed-off-by: Jacopo Mondi Signed-off-by: Hans de Goede --- Changes in v7: - Drop R-Car Gen4 mention from commit message Changes in v3: - New patch in v3 of this patch-series --- 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 Wed Aug 12 18:49:08 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: 27763 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 D7B41C3264 for ; Wed, 12 Aug 2026 18:49:29 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id 79B71682C8; Wed, 12 Aug 2026 20:49:29 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (2048-bit key; unprotected) header.d=qualcomm.com header.i=@qualcomm.com header.b="h3SSPc1T"; dkim=pass (2048-bit key; unprotected) header.d=oss.qualcomm.com header.i=@oss.qualcomm.com header.b="LuArBbWF"; 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 5B2B5682BA for ; Wed, 12 Aug 2026 20:49:27 +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 67CI8tPf382673 for ; Wed, 12 Aug 2026 18:49:26 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=tALQ4WPF1H+ xoBX9ywuRNg2hINLBVBQkINtnqbyHhYA=; b=h3SSPc1Tnn1C7Yi4FD3Vj3cDjPv jJ1bXBMSvMCuM/e20gqW3jIReS6XOj69ZSvBQBqL1EBcHFsgYFN7ymF2le3snS5x IwBhuxjyYtsp5LS5qTJhUdDzjMcoBDE6vlSRbffCoE2ad6BGJG5x7mNU7ZWEoEnR vf448jN89mW24T0b7tl8fx8bjuI/NcFIlH4gYhzVhH9jKpXkps4g16vs/8Kp4DRo hHpHEC6lCSImW6IDnLeeFG+LgAO8WwsA63aJZIXcuvobQKukvoTfQ5fPkLmKIJjt pLoHgwS+18wOj30/mdVOckt1URwUM+Pzicc2QP0ie3i6T+355GwnOqWDCOQ== Received: from mail-qt1-f199.google.com (mail-qt1-f199.google.com [209.85.160.199]) by mx0a-0031df01.pphosted.com (PPS) with ESMTPS id 4g0jgrkfyq-1 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NOT) for ; Wed, 12 Aug 2026 18:49:25 +0000 (GMT) Received: by mail-qt1-f199.google.com with SMTP id d75a77b69052e-51c1d7886cdso23024721cf.1 for ; Wed, 12 Aug 2026 11:49:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oss.qualcomm.com; s=google; t=1786560565; x=1787165365; 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:content-type; bh=tALQ4WPF1H+xoBX9ywuRNg2hINLBVBQkINtnqbyHhYA=; b=LuArBbWFv4v8uJWF9tSJuNnSFhJLHyIwfcXYkRzkNlw6q5gASaqjnHn9u8/BCnVnO5 sQmSypR/uLtJVnVPTs4hWMyhuqozxzcsizjy33ix5PEBH3bnByhR/0OskUQszeIhvkJd qb6j+bQLzWmuX6Co+1CIPbk4jiebVoKlr8Wob2ksX6s1sclaLmQP5C/qm1sJDFbObj3e HHDnhDCC+/U/XEs7jtPitZdbPwnjTagYNoHvDHoHN28O/4jfPwJpVLBAzRVra1Wx0B7B G4CrM7JGKyuC/PUUjfyCFmj2K4+6H1f0Cp6XU2xoS+dtS3ERU+NnZ19qB20z9CA04cpW G+mg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1786560565; x=1787165365; 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:content-type; bh=tALQ4WPF1H+xoBX9ywuRNg2hINLBVBQkINtnqbyHhYA=; b=CHkoS4u37t9uPr0R+jis6YZHloNi6nm8F1Spka24tKn0oyZggA9Jz1z0aXKw7LThWX 9+5I/qpWu2+UnWMS7wkIJH7d8SoZ2CSrNj0wMwM7/TwtJDBbMmCbaGZyYUr9t/wRxOwH fW7GX7gfvf9I6/ESwGvgoDQW7Dmd1dnUXmhkXESHcpwpgziapto2863hBz1b+lSeqV5O Jl2vW1c8hrWFyjAOJE3CsenKp6VeGv30Jp2w+OFB3ZQScCtnckg1vMvdGZQi4EeLdPIk NmERrLe6+gjDa3XjmkT5emlpYlWTEqDlyFbzvdNssqW7zIq6z9O22tHph1wypOQlc2U/ l/zw== X-Gm-Message-State: AOJu0YyWmpfwmwtb7T0Pr2Fsxy6sKE4Cs/zfWk5GmaMY2JVeMcl9w9fO Mt7LuYVlELdfskZusH2hBuRw+MU4cXw5Xrvp2X4RH4hIzDQ6dTEAN4zkSmUisUoqbfB0RrfSyWz dcWldwrLFBReApitjBEgJU5Vtj940CQvR2ZJ0exhVz60KZ6d58NS/blyQgE3KKZPaZUcxlYIAgX 1w1OWUECV0 X-Gm-Gg: AR+sD11jRZgU8aBvrL02A1U/y031faRLHq2WRpejULHxuIjcR62BFC5pyECXgiyNZFv AVIxrtjpbA+f51YvXY1f2VawyAdopR4nSKBRRBYEjXSETFX78ZxHgUEmvtSRkdrXQ+wQIPoI+Cq NMaMTtRoXZfyjYgQVyGrFTBjvCu131f97iFcP50A98wCEL9lQxiUPS2IhTpWQC19x18ZA1YKvGy yw6dHiTadUIGBnklr1bTr3avjrRTbVxlADjmJO8fPVr+6V+K3nQL9W4t2Y6+8K66ve0y/sIv1O7 exPeI+L/SsLkJhHPkX+fq0FoqY3oLp40Y/vUi1MCmT1YGq2FnglA3kCxeDjmcvBmex+lOqs5oq5 IXDiecV3LF6b/MBU4CtosvZDB2caxMQDJhNrdsvrBPzo/a4WOijgiMW8+zKqjoO0D/qdz+tXkPf hzTOTNTm2b7FqAE+8= X-Received: by 2002:a05:622a:4c0c:b0:51c:849b:86b with SMTP id d75a77b69052e-52d73e744cdmr2335691cf.43.1786560565247; Wed, 12 Aug 2026 11:49:25 -0700 (PDT) X-Received: by 2002:a05:622a:4c0c:b0:51c:849b:86b with SMTP id d75a77b69052e-52d73e744cdmr2335401cf.43.1786560564909; Wed, 12 Aug 2026 11:49:24 -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 4fb4d7f45d1cf-6a37f8a202fsm52348a12.15.2026.08.12.11.49.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 12 Aug 2026 11:49:23 -0700 (PDT) From: Hans de Goede To: libcamera-devel@lists.libcamera.org Cc: Loic Poulain , Hans de Goede , Jacopo Mondi Subject: [PATCH v7 4/8] pipeline: rpi: Explictly pass pipe()->name() when creating IPA Date: Wed, 12 Aug 2026 20:49:08 +0200 Message-ID: <20260812184912.287894-5-johannes.goede@oss.qualcomm.com> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260812184912.287894-1-johannes.goede@oss.qualcomm.com> References: <20260812184912.287894-1-johannes.goede@oss.qualcomm.com> MIME-Version: 1.0 X-Proofpoint-Spam-Details-Enc: AW1haW4tMjYwODEyMDE1MSBTYWx0ZWRfX3+iUB6Drnf6T DsMyHuosox51Z5zfeIznXVHrGEpvYt7nBMDM8wGLq9fXO0e/MbtuiOLIZfP0pQH0TB8wLeCc9LU NZQ6XbX42muIn4kLVK9IBm+Z9iP4phHLXbp0r6CmRJAg5SY9jEvrpU0izufP0urw4ANI3fjLnvc 4hsqx9JUHdh524LfL255uAnv9lADAODOvc5KFSP6nckSBrUPqNFxtgm3PkQHixYEPHzXpQsPUc4 QNot2FS1WkpQqtJem0OMXDW89MleZ6I/JjbyLShZb08SfCSu9t2T4EbeJxxbZAvpUSL4bVUbt9k qrFmBCbjmBGN6u9Q9cY67lavTV8viQq+1OHdW6HOA8q8DWGt+C+RnWtXN2eADArSRqJRtPbthIj myJgIz9KSU5ezXAu2ZMRuydD0/eSA6JwmW7bw1GR61Aq56qDQ/FPHNAEy5rgGWSkacB5GbDE0hU jyzHcCocaS2sr3Wmxew== X-Proofpoint-ORIG-GUID: yCH2N4KDQb9UMxv50R4FU2fB_prlWNbP X-Authority-Analysis: v=2.4 cv=TNJ1jVla c=1 sm=1 tr=0 ts=6a7cc035 cx=c_pps a=WeENfcodrlLV9YRTxbY/uA==:117 a=xqWC_Br6kY4A:10 a=Sv0fKeRqtYgA:10 a=s4-Qcg_JpJYA:10 a=VkNPw1HP01LnGYTKEx00:22 a=u7WPNUs3qKkmUXheDGA7:22 a=gowsoOTTUOVcmtlkKump:22 a=P1BnusSwAAAA:8 a=EUspDBNiAAAA:8 a=PI23gj2s8gul_AyujO4A:9 a=kacYvNCVWA4VmyqE58fU:22 a=D0XLA9XvdZm18NrgonBM:22 X-Proofpoint-GUID: yCH2N4KDQb9UMxv50R4FU2fB_prlWNbP X-Proofpoint-Spam-Info: AW1haW4tMjYwODEyMDE1MSBTYWx0ZWRfX+5ndk3rGj3IU 1od/S5reTScKW22xZDXFTTOCnSt+5bJUG6hbIlJCzgreC+zUwHBh1apy+ha3S/BD3DklfOd5v6x D8d9U041+fe18J3MkPWYyBMBPWqoGjE= X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293, Aquarius:18.0.1176, Hydra:6.1.134, FMLib:17.12.100.49 definitions=2026-08-12_05,2026-08-12_01,2025-10-01_01 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 clxscore=1015 priorityscore=1501 phishscore=0 impostorscore=0 adultscore=0 suspectscore=0 bulkscore=0 spamscore=0 lowpriorityscore=0 malwarescore=0 classifier=typeunknown authscore=0 authtc= authcc= route=outbound adjust=0 reason=mlx scancount=1 engine=8.22.0-2606150000 definitions=main-2608120151 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" Switch to explicitly specifying the pipeline-name as the name of the IPA to create. This is a preparation patch for switching the default IPA creation to matching IPA by IPA proxy type, which does not work for rpi because the same IPAProxyRPi type is used for both the rpi/vc4 and rpi/pisp pipeline handlers. Reviewed-by: Jacopo Mondi Signed-off-by: Hans de Goede --- Changes in v7: - Add a comment explaining why pipe()->name() is used when creating the IPA Changes in v6: - New patch in v6 of this patch-series --- src/libcamera/pipeline/rpi/common/pipeline_base.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/libcamera/pipeline/rpi/common/pipeline_base.cpp b/src/libcamera/pipeline/rpi/common/pipeline_base.cpp index 5a5acf6a1..802b2b3c7 100644 --- a/src/libcamera/pipeline/rpi/common/pipeline_base.cpp +++ b/src/libcamera/pipeline/rpi/common/pipeline_base.cpp @@ -1165,7 +1165,13 @@ int CameraData::loadIPA(ipa::RPi::InitResult *result) { int ret; - ipa_ = pipe()->createIPA(1, 1); + /* + * Explicitly pass pipe()->name() to select the IPA to create. + * The default behavior of creating the IPA by the IPA proxy type name + * does not work because the same IPAProxyRPi type is used for both + * the rpi/vc4 and rpi/pisp pipeline handlers. + */ + ipa_ = pipe()->createIPA(pipe()->name(), 1, 1); if (!ipa_) return -ENOENT;