linux-stable/drivers/media/platform/rockchip
Laurent Pinchart efa28efd9c media: rkisp1: resizer: Stop manual allocation of v4l2_subdev_state
Supported media bus codes on the resizer sink pad are identical to the
ISP source pad. The .enum_mbus_code() handler thus delegates the
enumeration to the ISP's operation. This is problematic for two
reasons:

- Format enumeration on the ISP source pad is dependent on the format
  configured on the ISP sink pad for the same subdev state (TRY or
  ACTIVE), while format enumeration on the resizer sink pad should
  return all formats supported by the resizer subdev, regardless of the
  ISP configuration.

- Delegating the operation involves creating a fake v4l2_subdev_state on
  the stack to pass to the ISP .enum_mbus_code() handler. This gets in
  the way of evolution of both the ISP enumeration handler and, more
  generally, the V4L2 subdev state infrastructure.

Fix those two issues by implementing format enumeration manually for the
resizer.

Link: https://lore.kernel.org/r/20231126020948.2700-1-laurent.pinchart@ideasonboard.com

Reviewed-by: Paul Elder <paul.elder@ideasonboard.com>
Reviewed-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
2023-12-09 07:47:10 +01:00
..
rga media: rockchip: rga: add NV12M support 2023-12-07 08:56:14 +01:00
rkisp1 media: rkisp1: resizer: Stop manual allocation of v4l2_subdev_state 2023-12-09 07:47:10 +01:00
Kconfig media: platform/*/Kconfig: make manufacturer menus more uniform 2022-03-18 05:58:35 +01:00
Makefile media: platform: Create vendor/{Makefile,Kconfig} files 2022-03-18 05:58:35 +01:00