mbox series

[v6,0/2] Enable support for error detection in CSI2RX

Message ID 20250416121938.346435-1-y-abhilashchandra@ti.com
Headers show
Series Enable support for error detection in CSI2RX | expand

Message

Yemike Abhilash Chandra April 16, 2025, 12:19 p.m. UTC
This patch series enables the csi2rx_err_irq interrupt to record any errors
that occur during streaming. It also adds support for the VIDIOC_LOG_STATUS
ioctl, which outputs the current device status to the kernel log.

The IRQ handler records any errors encountered during streaming.
Additionally, VIDIOC_LOG_STATUS can be invoked from user space to retrieve
the latest status.

Changelog:
Changes in v6:
- Although the interrupt mask is configured only for cdns-csi2rx source pads
  with active remote connections, the IRQ handler currently records all events
  regardless of whether they are enabled in the mask. Since the events are not
  mutually exclusive, a stream overflow event for a pad without an active remote
  can be recorded if it occurs in parallel with any event enabled in the mask.
  To avoid this, update the handler to record only those events that are explicitly
  enabled in the mask, preventing unnecessary logging for pads without an active
  remote connection.
- Drop the Reviewed-by and Tested-by tags from Jai and Changhuang, as this
  version introduces a minor change in the IRQ handling logic.

v5: https://lore.kernel.org/all/20250228114030.1028443-1-y-abhilashchandra@ti.com/

Yemike Abhilash Chandra (2):
  dt-bindings: media: cdns,csi2rx.yaml: Add optional interrupts for
    cdns-csi2rx
  media: cadence: csi2rx: Enable csi2rx_err_irq interrupt and add
    support for VIDIOC_LOG_STATUS

 .../bindings/media/cdns,csi2rx.yaml           |   8 ++
 drivers/media/platform/cadence/cdns-csi2rx.c  | 131 ++++++++++++++++++
 2 files changed, 139 insertions(+)