mbox series

[v4,0/4] rcar-vin: Add support for RGB formats with alpha component

Message ID 20190704171602.29541-1-niklas.soderlund+renesas@ragnatech.se (mailing list archive)
Headers show
Series rcar-vin: Add support for RGB formats with alpha component | expand

Message

Niklas Söderlund July 4, 2019, 5:15 p.m. UTC
Hi,

This small series adds support for two new pixel formats for the
rcar-vin driver; V4L2_PIX_FMT_ARGB555 and V4L2_PIX_FMT_ABGR32. Both
formats have an alpha component so a new standard control is also added
to control its value, V4L2_CID_ALPHA_COMPONENT.

The series is based on the latest media-tree and is tested on both
Renesas Gen2 and Gen3 hardware without any regressions found.

Patch 1/4 fixes a badly named register name, 2/4 adds the new control
while 3/4 adds the two new pixel formats. Patch 4/4 is a clean up now
that Gen2 and Gen3 always have controls and v4l2_ctrl_handler_setup()
should be called for both cases.

* Changes since v3
- Fixed up commit message.
- Collected review tags.

* Changes since v2
- Protect the writing of the alpha value when streaming with the spin
  lock to make sure the streaming state is stable.
- Add patch 4/4 to call v4l2_ctrl_handler_setup() for the media
  controller centric Gen3 mode of the driver.

Niklas Söderlund (4):
  rcar-vin: Rename VNDMR_DTMD_ARGB1555 to VNDMR_DTMD_ARGB
  rcar-vin: Add control for alpha component
  rcar-vin: Add support for RGB formats with alpha component
  rcar-vin: Always setup controls when opening video device

 drivers/media/platform/rcar-vin/rcar-core.c | 53 ++++++++++++++++++++-
 drivers/media/platform/rcar-vin/rcar-dma.c  | 44 ++++++++++++++++-
 drivers/media/platform/rcar-vin/rcar-v4l2.c | 38 +++++++++------
 drivers/media/platform/rcar-vin/rcar-vin.h  |  5 ++
 4 files changed, 121 insertions(+), 19 deletions(-)