media: mc: Expand MUST_CONNECT flag to always require an enabled link
Subsystems (3)
This is an automatic generated email to let you know that the following patch were queued:
Subject: media: mc: Expand MUST_CONNECT flag to always require an enabled link Author: Laurent Pinchart <[email protected]> Date: Mon Jan 15 01:04:52 2024 +0200
The MEDIA_PAD_FL_MUST_CONNECT flag indicates that the pad requires an enabled link to stream, but only if it has any link at all. This makes little sense, as if a pad is part of a pipeline, there are very few use cases for an active link to be mandatory only if links exist at all. A review of in-tree drivers confirms they all need an enabled link for pads marked with the MEDIA_PAD_FL_MUST_CONNECT flag.
Expand the scope of the flag by rejecting pads that have no links at all. This requires modifying the pipeline build code to add those pads to the pipeline.
Cc [email protected] # 6.1
Signed-off-by Laurent Pinchart <[email protected]>
Acked-by Sakari Ailus <[email protected]>
Signed-off-by Hans Verkuil <[email protected]>
.../userspace-api/media/mediactl/media-types.rst | 11 ++--- drivers/media/mc/mc-entity.c | 53 ++++++++++++++++++---- 2 files changed, 48 insertions(+), 16 deletions(-)
---
Documentation/userspace-api/media/mediactl/media-types.rst +5 -6
@@ -375,12 +375,11 @@ Types and flags used to represent the media graph elements are origins of links. * - ``MEDIA_PAD_FL_MUST_CONNECT`` - - If this flag is set and the pad is linked to any other pad, then - at least one of those links must be enabled for the entity to be - able to stream. There could be temporary reasons (e.g. device - configuration dependent) for the pad to need enabled links even - when this flag isn't set; the absence of the flag doesn't imply - there is none. + - If this flag is set, then for this pad to be able to stream, it must + be connected by at least one enabled link. There could be temporary + reasons (e.g. device configuration dependent) for the pad to need + enabled links even when this flag isn't set; the absence of the flag + doesn't imply there is none. One and only one of ``MEDIA_PAD_FL_SINK`` and ``MEDIA_PAD_FL_SOURCE``
drivers/media/mc/mc-entity.c +43 -10
122 lines not on this page · raw message