[v2,0/2] ipa: Allow IPA creation by name
mbox series

Message ID 20251003-ipa-match-by-name-v2-0-54f3cd828ddd@ideasonboard.com
Headers show
Series
  • ipa: Allow IPA creation by name
Related show

Message

Jacopo Mondi Oct. 3, 2025, 4:16 p.m. UTC
It is getting more and more common for different pipeline handlers to
use the same IPA modules whose name differs from the pipeline's one.

The first case has been the softISP, and now the in-review Renesas R-Car
V4H pipeline handler will re-use the RkISP1 IPA.

Starting from Hans' patch https://patchwork.libcamera.org/patch/23359/
"libcamera: ipa_manager: createIPA: Allow matching by IPA name instead
of by pipeline" I here took a slightly different approach and addressed
the review comments on Hans' v1 by creating an overload for
IPAManager::createIPA() that allows pipelines to specify the IPA module
name. If they don't provide a name, the pipeline handler's name is used.

As the next step, to further decouple IPAs from pipelines, remove the
pipelineName field from IPAModuleInfo that in all cases is identical to
the IPA name itself.

Not tested on neither softISP or R-Car but I used the "by name" and "by
pipe" overloads on Mali and it worked.

Signed-off-by: Jacopo Mondi <jacopo.mondi@ideasonboard.com>
---
Changes in v2:
- Changed Hans authorship to different email address
- Removed stray blank line
- Collect tags
- Link to v1: https://lore.kernel.org/r/20251003-ipa-match-by-name-v1-0-07b796729412@ideasonboard.com

---
Hans de Goede (1):
      libcamera: ipa_manager: Create IPA by name

Jacopo Mondi (1):
      ipa: ipa_module: Remove pipelineName

 include/libcamera/internal/ipa_manager.h | 13 ++++++++++--
 include/libcamera/internal/ipa_module.h  |  4 ++--
 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_manager.cpp            | 34 ++++++++++++++++++++++++++------
 src/libcamera/ipa_module.cpp             | 27 +++++++++++--------------
 test/ipa/ipa_module_test.cpp             |  3 ---
 13 files changed, 53 insertions(+), 36 deletions(-)
---
base-commit: f0f2aca56611bf9430eb6edc23e9bd55cf96a26d
change-id: 20251002-ipa-match-by-name-82e6b34a23e9

Best regards,