]> git.baikalelectronics.ru Git - kernel.git/commitdiff
media: videobuf2-core: embed media_request_object
authorHans Verkuil <hans.verkuil@cisco.com>
Mon, 21 May 2018 08:54:46 +0000 (04:54 -0400)
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Fri, 31 Aug 2018 15:17:57 +0000 (11:17 -0400)
Make vb2_buffer a request object.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Reviewed-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
include/media/videobuf2-core.h

index 2eb24961183e7a7c5ec24bf426467b7b23dc3d6d..413b8b2dc48517bba4c03fc9f3060adc0c8fda9b 100644 (file)
@@ -17,6 +17,7 @@
 #include <linux/poll.h>
 #include <linux/dma-buf.h>
 #include <linux/bitops.h>
+#include <media/media-request.h>
 
 #define VB2_MAX_FRAME  (32)
 #define VB2_MAX_PLANES (8)
@@ -236,6 +237,8 @@ struct vb2_queue;
  * @num_planes:                number of planes in the buffer
  *                     on an internal driver queue.
  * @timestamp:         frame timestamp in ns.
+ * @req_obj:           used to bind this buffer to a request. This
+ *                     request object has a refcount.
  */
 struct vb2_buffer {
        struct vb2_queue        *vb2_queue;
@@ -244,6 +247,7 @@ struct vb2_buffer {
        unsigned int            memory;
        unsigned int            num_planes;
        u64                     timestamp;
+       struct media_request_object     req_obj;
 
        /* private: internal use only
         *