[media] media: videobuf2-core.h: add a helper to get status of start_streaming()
authorPrabhakar Lad <prabhakar.csengg@gmail.com>
Sat, 6 Sep 2014 15:26:49 +0000 (12:26 -0300)
committerMauro Carvalho Chehab <mchehab@osg.samsung.com>
Sun, 21 Sep 2014 23:15:39 +0000 (20:15 -0300)
this patch adds a helper to get the status if start_streaming()
was called successfully.

Signed-off-by: Lad, Prabhakar <prabhakar.csengg@gmail.com>
Cc: Pawel Osciak <pawel@osciak.com>
Cc: Marek Szyprowski <m.szyprowski@samsung.com>
Cc: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
include/media/videobuf2-core.h

index 5a10d8d..b3c9973 100644 (file)
@@ -590,6 +590,15 @@ vb2_plane_size(struct vb2_buffer *vb, unsigned int plane_no)
        return 0;
 }
 
+/**
+ * vb2_start_streaming_called() - return streaming status of driver
+ * @q:         videobuf queue
+ */
+static inline bool vb2_start_streaming_called(struct vb2_queue *q)
+{
+       return q->start_streaming_called;
+}
+
 /*
  * The following functions are not part of the vb2 core API, but are simple
  * helper functions that you can use in your struct v4l2_file_operations,