[v1,0/3] Atomic control lists on Raspberry Pi
mbox series

Message ID 20260324151714.3345-1-david.plowman@raspberrypi.com
Headers show
Series
  • Atomic control lists on Raspberry Pi
Related show

Message

David Plowman March 24, 2026, 2:32 p.m. UTC
Hi

Currently, on Raspberry Pi, when control lists are submitted in a
request, they are not all applied on the same frame. "Immediate" (or
ISP controls) can be applied instantly, and will therefore happen
several frames before the "delayed" controls (like exposure time,
analogue gain and so on which require us to wait for the sensor).

This small patch set fixes that by holding back the immediate
controls, until the delayed controls submitted in the same request,
have happened.

As we already have the necessary information, we can also flag every
request with the sequence number of the request whose control list has
actually just been applied, which we do using the "ControlId"
metadata.

This first patch is some tidying that came out of doing this work, but
is not otherwise terribly significant (beyond being correct or not!).

The second patch defines the "ControlId" control, and the final patch
contains the bulk of the changes.

Thanks!
David

David Plowman (3):
  pipeline: rpi: Simplify delayed controls
  controls: rpi: Add ControlId control
  pipeline: rpi: Make control lists in requests properly atomic

 src/ipa/rpi/common/ipa_base.cpp               | 24 ++++++----
 src/libcamera/control_ids_rpi.yaml            | 10 ++++
 .../pipeline/rpi/common/delayed_controls.cpp  | 22 ++++-----
 .../pipeline/rpi/common/delayed_controls.h    |  1 -
 .../pipeline/rpi/common/pipeline_base.cpp     | 46 +++++++++++++++++++
 .../pipeline/rpi/common/pipeline_base.h       |  8 ++++
 src/libcamera/pipeline/rpi/pisp/pisp.cpp      |  3 ++
 src/libcamera/pipeline/rpi/vc4/vc4.cpp        |  3 ++
 8 files changed, 96 insertions(+), 21 deletions(-)