[v2,0/7] camss: Add CAMSS pipeline handler
mbox series

Message ID 20260721145958.68489-1-johannes.goede@oss.qualcomm.com
Headers show
Series
  • camss: Add CAMSS pipeline handler
Related show

Message

Hans de Goede July 21, 2026, 2:59 p.m. UTC
Hi All,

Add a CAMSS pipeline handler. This series consists of 2 parts:

1. A basic version which basically replaces the simple pipeline handler
camss support, while still using the softISP. Compared to the simple
pipeline handler this gains us support for streaming from multiple
cameras at once (through pipewire) since this assigns unique csid and
vfe resources to each camera rather then always using csid0 + vfe0 for
all cameras.

This consists of patches 1-4 and this is necessary to support
simultaneous streaming of multiple cameras on the Arduino UNO Q and
the upcoming Arduino VENTUNO Q, as such we would like to get this
upstream ASAP (*).

2. Patches 5-7 add support for the Offline Processing Engine (OPE) offline
ISP found on the Dragonwing QRB2210 (Agatti) SoC. This is based on the v4
OPE kernel patch-series:
https://lore.kernel.org/linux-media/20260710-camss-isp-ope-v4-0-51207a0319d8@oss.qualcomm.com/

This part of the patch series is more in a RFC status, because:
a) The kernel patches are not yet accepted so the uAPI might still change
b) ATM it (ab)uses the softISP IPA instead of using its own IPA, the plan
is to change this for the next version, based on the ongoing libipa rework
on the list.

Changes since the v1/RFC (**) series:
- Drop fine grained locking support. This is replaced with using pipewire
  to allow simultaneous access to multiple cameras while still having only
  a single libcamera instance access, removing the need for fine grained
  locking
- Add 2 small preperation patches + a camss_util.cpp file with some helper
  functions
- The OPE pipeline-handling is now based on the v4 kernel series which
  introduces a proper media-controller centric ISP driver with multiple
  input queues (raw-frames + parameters) replacing the previous M2M based
  proof-of-concept kernel driver
- Add linux/camss-config.h+camss_params.h using the generic ISP parameters
  framework (these are subject to change until the kernel driver is merged)

Since this will replace the simple pipeline handler support more
testing on other platforms with different camera setups, e.g. various
phones would be appreciated to avoid e.g. postmarketOS camera support
regressing when this lands.

Regards,

Hans


*) This still depends on:
https://patchwork.libcamera.org/project/libcamera/list/?series=5940 +
https://patchwork.libcamera.org/patch/26750/

A branch with this series + the pre-requisite patches is here:
https://github.com/jwrdegoede/libcamera/commits/camss_pipeline_v2/

We really need to get this resolved, I see that Jacopo has also reposted
this in:
https://patchwork.libcamera.org/project/libcamera/list/?series=6003

Since that series also relies on having a different way to select which
IPA to load then matching by the pipeline name.

I've an idea to move this closer to what Laurent wants to see without
needing to make significant changes to the Rasberry Pi code. I'll to get
something posted this week.

**) https://lists.libcamera.org/pipermail/libcamera-devel/2026-April/058087.html


Hans de Goede (7):
  libcamera: V4L2Subdevice: Add whence argument to [get|set]Selection()
  software_isp: Rename simple IPA setIspParams signal to paramsComputed
  camss: Add cammss utility functions
  camss: Add camss pipeline handler
  camss: Add include/linux/camss-config.h
  camss: Add camss_params.h
  camss: Add Offline Processing Engine ISP support

 .../internal/software_isp/software_isp.h      |   2 +-
 include/libcamera/internal/v4l2_subdevice.h   |  14 +-
 include/libcamera/ipa/soft.mojom              |   2 +-
 include/linux/camss-config.h                  | 161 ++++
 meson.build                                   |   1 +
 meson_options.txt                             |   1 +
 src/ipa/meson.build                           |   1 +
 src/ipa/simple/soft_simple.cpp                |   2 +-
 src/libcamera/pipeline/camss/camss.cpp        | 696 ++++++++++++++++++
 src/libcamera/pipeline/camss/camss_csi.cpp    | 570 ++++++++++++++
 src/libcamera/pipeline/camss/camss_csi.h      | 131 ++++
 src/libcamera/pipeline/camss/camss_frames.cpp | 155 ++++
 src/libcamera/pipeline/camss/camss_frames.h   |  71 ++
 src/libcamera/pipeline/camss/camss_isp.cpp    |  26 +
 src/libcamera/pipeline/camss/camss_isp.h      |  62 ++
 .../pipeline/camss/camss_isp_ope.cpp          | 679 +++++++++++++++++
 src/libcamera/pipeline/camss/camss_isp_ope.h  | 120 +++
 .../pipeline/camss/camss_isp_soft.cpp         | 226 ++++++
 src/libcamera/pipeline/camss/camss_isp_soft.h |  56 ++
 src/libcamera/pipeline/camss/camss_params.h   |  67 ++
 src/libcamera/pipeline/camss/camss_util.cpp   |  39 +
 src/libcamera/pipeline/camss/camss_util.h     |  19 +
 src/libcamera/pipeline/camss/meson.build      |  13 +
 src/libcamera/pipeline/simple/simple.cpp      |   1 -
 src/libcamera/software_isp/software_isp.cpp   |   4 +-
 src/libcamera/v4l2_subdevice.cpp              |  20 +-
 26 files changed, 3121 insertions(+), 18 deletions(-)
 create mode 100644 include/linux/camss-config.h
 create mode 100644 src/libcamera/pipeline/camss/camss.cpp
 create mode 100644 src/libcamera/pipeline/camss/camss_csi.cpp
 create mode 100644 src/libcamera/pipeline/camss/camss_csi.h
 create mode 100644 src/libcamera/pipeline/camss/camss_frames.cpp
 create mode 100644 src/libcamera/pipeline/camss/camss_frames.h
 create mode 100644 src/libcamera/pipeline/camss/camss_isp.cpp
 create mode 100644 src/libcamera/pipeline/camss/camss_isp.h
 create mode 100644 src/libcamera/pipeline/camss/camss_isp_ope.cpp
 create mode 100644 src/libcamera/pipeline/camss/camss_isp_ope.h
 create mode 100644 src/libcamera/pipeline/camss/camss_isp_soft.cpp
 create mode 100644 src/libcamera/pipeline/camss/camss_isp_soft.h
 create mode 100644 src/libcamera/pipeline/camss/camss_params.h
 create mode 100644 src/libcamera/pipeline/camss/camss_util.cpp
 create mode 100644 src/libcamera/pipeline/camss/camss_util.h
 create mode 100644 src/libcamera/pipeline/camss/meson.build