mbox series

[v8,0/3] media: i2c: Add support for alvium camera

Message ID 20230914154758.1795663-1-tomm.merciai@gmail.com
Headers show
Series media: i2c: Add support for alvium camera | expand

Message

Tommaso Merciai Sept. 14, 2023, 3:47 p.m. UTC
Hi all,
Back on topic :).

This series add support for Allied Vision Alvium camera.
The Alvium camera is shipped with sensor + isp in the same housing.
The camera can be equipped with one out of various sensor and abstract
the user from this. Camera is connected via MIPI CSI-2.

I have rebase v8 on top of media-stage branch [1].
Test was done taking as refence last build tooling from
HVerkuil[2]. Thanks to this tool I'm able to fix the following
warnings:

drivers/media/i2c/alvium-csi2.c:398:18: warning: incorrect type in assignment (different base types)
drivers/media/i2c/alvium-csi2.c:398:18:    expected unsigned short [usertype] minor
drivers/media/i2c/alvium-csi2.c:398:18:    got restricted __le16 [usertype]
drivers/media/i2c/alvium-csi2.c:399:18: warning: incorrect type in assignment (different base types)
drivers/media/i2c/alvium-csi2.c:399:18:    expected unsigned short [usertype] major
drivers/media/i2c/alvium-csi2.c:399:18:    got restricted __le16 [usertype]
drivers/media/i2c/alvium-csi2.c:416:21: warning: incorrect type in assignment (different base types)
drivers/media/i2c/alvium-csi2.c:416:21:    expected unsigned short [usertype] minor
drivers/media/i2c/alvium-csi2.c:416:21:    got restricted __le16 [usertype]
drivers/media/i2c/alvium-csi2.c:417:21: warning: incorrect type in assignment (different base types)
drivers/media/i2c/alvium-csi2.c:417:21:    expected unsigned int [usertype] patch
drivers/media/i2c/alvium-csi2.c:417:21:    got restricted __le32 [usertype]
drivers/media/usb/siano/smsusb.c:53:38: warning: array of flexible structures

drivers/media/i2c/alvium-csi2.c:2665 alvium_probe() warn: missing error code? 'ret'
drivers/media/i2c/alvium-csi2.c:2671 alvium_probe() warn: ignoring unreachable code.
drivers/media/usb/siano/smsusb.c:53:38: warning: array of flexible structures.


Driver use last v4l2 CCI API.
This driver has been tested on the following scenario:

 alvium-csi2 -> imx8mp-evk (isi pixel pipeline)

Thanks & Regards,
Tommaso

[1] - https://git.linuxtv.org/media_stage.git/tree/Documentation/devicetree/bindings/vendor-prefixes.yaml
[2] - https://git.linuxtv.org/hverkuil/build-scripts.git

Tommaso Merciai (3):
  dt-bindings: vendor-prefixes: Add prefix alliedvision
  media: dt-bindings: alvium: add document YAML binding
  media: i2c: Add support for alvium camera

 .../media/i2c/alliedvision,alvium-csi2.yaml   |   97 +
 .../devicetree/bindings/vendor-prefixes.yaml  |    2 +
 MAINTAINERS                                   |    9 +
 drivers/media/i2c/Kconfig                     |   11 +
 drivers/media/i2c/Makefile                    |    1 +
 drivers/media/i2c/alvium-csi2.c               | 2761 +++++++++++++++++
 drivers/media/i2c/alvium-csi2.h               |  474 +++
 7 files changed, 3355 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/media/i2c/alliedvision,alvium-csi2.yaml
 create mode 100644 drivers/media/i2c/alvium-csi2.c
 create mode 100644 drivers/media/i2c/alvium-csi2.h