]> git.baikalelectronics.ru Git - kernel.git/commit
media: media-request: add media_request_object_find
authorHans Verkuil <hans.verkuil@cisco.com>
Mon, 21 May 2018 08:54:29 +0000 (04:54 -0400)
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Fri, 31 Aug 2018 15:07:08 +0000 (11:07 -0400)
commitcd1aacbaa3be27b111bb774ac0c012c1c3e1b016
treec26d8b7336aa27649e2a0470dcc1ec6921950ddd
parentd3ebb93a04588fad2f805bce3e911224e348b435
media: media-request: add media_request_object_find

Add media_request_object_find to find a request object inside a
request based on ops and priv values.

Objects of the same type (vb2 buffer, control handler) will have
the same ops value. And objects that refer to the same 'parent'
object (e.g. the v4l2_ctrl_handler that has the current driver
state) will have the same priv value.

The caller has to call media_request_object_put() for the returned
object since this function increments the refcount.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Acked-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Reviewed-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
drivers/media/media-request.c
include/media/media-request.h