OSDN Git Service

media: microchip: microchip-isc: prepare for media controller support
authorEugen Hristev <eugen.hristev@microchip.com>
Mon, 7 Nov 2022 14:18:15 +0000 (16:18 +0200)
committerHans Verkuil <hverkuil-cisco@xs4all.nl>
Fri, 18 Nov 2022 14:48:18 +0000 (15:48 +0100)
commitde32105cbe3c6f334c3ddc5c493efeeb439764be
tree27e0978794e61b029f34215c47482e0cd68624df
parenta5517d53d4a69b8e8c46befc7f905278e78c3459
media: microchip: microchip-isc: prepare for media controller support

Prepare the support for media-controller.
This means that the capabilities of the driver have changed and now it's
capable of media controller operations.
The driver will register its media device, and add the video entity to this
media device. The subdevices are registered to the same media device.
The ISC will have a base entity which is auto-detected as
microchip_isc_base.
It will also register a subdevice that allows cropping of the incoming
frame to the maximum frame size supported by the ISC.
The ISC will create a link between the subdevice that is asynchronously
registered and the microchip_isc_scaler entity.
Then, the microchip_isc_scaler and microchip_isc_base are connected
through another link.
This patch does not change the previous capability of the driver, the
fact that the format is still being propagated from the top video node
down to the sensor.

Signed-off-by: Eugen Hristev <eugen.hristev@microchip.com>
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
drivers/media/platform/microchip/Makefile
drivers/media/platform/microchip/microchip-isc-base.c
drivers/media/platform/microchip/microchip-isc-scaler.c [new file with mode: 0644]
drivers/media/platform/microchip/microchip-isc.h
drivers/media/platform/microchip/microchip-sama5d2-isc.c
drivers/media/platform/microchip/microchip-sama7g5-isc.c