media: add V4L2_SUBDEV_FL_STREAMS
authorTomi Valkeinen <tomi.valkeinen@ideasonboard.com>
Thu, 29 Jul 2021 13:02:04 +0000 (15:02 +0200)
committerMauro Carvalho Chehab <mchehab@kernel.org>
Sun, 22 Jan 2023 08:29:46 +0000 (09:29 +0100)
Add subdev flag V4L2_SUBDEV_FL_STREAMS. It is used to indicate that the
subdev supports the new API with multiplexed streams (routing, stream
configs).

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
include/media/v4l2-subdev.h

index b15fa9930f30c16e5512fb8544c2cce9691c8bbe..95361b54108792ccff2f2dd7d909f6f9fa7fb3a7 100644 (file)
@@ -884,6 +884,17 @@ struct v4l2_subdev_internal_ops {
  * should set this flag.
  */
 #define V4L2_SUBDEV_FL_HAS_EVENTS              (1U << 3)
+/*
+ * Set this flag if this subdev supports multiplexed streams. This means
+ * that the driver supports routing and handles the stream parameter in its
+ * v4l2_subdev_pad_ops handlers. More specifically, this means:
+ *
+ * - Centrally managed subdev active state is enabled
+ * - Legacy pad config is _not_ supported (state->pads is NULL)
+ * - Routing ioctls are available
+ * - Multiple streams per pad are supported
+ */
+#define V4L2_SUBDEV_FL_STREAMS                 (1U << 4)
 
 struct regulator_bulk_data;