summaryrefslogtreecommitdiff
path: root/tools/testing/vma/include/git@git.tavy.me:linux.git
diff options
context:
space:
mode:
authorTomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>2026-03-17 14:09:42 +0200
committerHans Verkuil <hverkuil+cisco@kernel.org>2026-03-24 11:58:02 +0100
commit64d712aa31f30a125291e7c47209ef7ebd3285a3 (patch)
tree49f77dfd7d59b415fc03a4907b9d1f7cf032c935 /tools/testing/vma/include/git@git.tavy.me:linux.git
parentf40306e08627bd4a51a1bcdc4ec864209448bdc0 (diff)
media: subdev: Split v4l2_subdev_get_frame_desc_passthrough() into locked and unlocked
The recently added v4l2_subdev_get_frame_desc_passthrough() can be used directly as an implementation for .get_frame_desc subdev op. However, in some cases the drivers may want to add some customizations, while the bulk of the work is still identical to what v4l2_subdev_get_frame_desc_passthrough() does. Current locking scheme makes this impossible to do properly. Split v4l2_subdev_get_frame_desc_passthrough() into two functions: __v4l2_subdev_get_frame_desc_passthrough(), which takes a locked subdev state as a parameter, instead of locking and getting the active state internally. Other than that, it does the same as v4l2_subdev_get_frame_desc_passthrough() used to do. v4l2_subdev_get_frame_desc_passthrough(), which locks the active state and calls __v4l2_subdev_get_frame_desc_passthrough(). In other words, v4l2_subdev_get_frame_desc_passthrough() works as before, but drivers can now alternatively add custom .get_frame_desc code and call v4l2_subdev_get_frame_desc_passthrough(). An example use case is with DS90UB953 serializer: in normal use the serializer passes through everything, but when test-pattern-generator (TPG) is used, an internal TPG source is used. After this commit, the UB953 get_frame_desc() can lock the state, look at the routing table to see if we're in normal or TPG mode, then either call __v4l2_subdev_get_frame_desc_passthrough() if in normal mode, or construct a TPG frame desc if in TPG mode. Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com> [Sakari Ailus: Rebase on an earlier remote source pad error code fix.] Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com> Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
Diffstat (limited to 'tools/testing/vma/include/git@git.tavy.me:linux.git')
0 files changed, 0 insertions, 0 deletions