summaryrefslogtreecommitdiff
path: root/yavta.c
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2010-06-02 14:21:31 +0200
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2010-06-02 14:21:31 +0200
commit09cb44f779ed77c1c9dc388bd4faf3ae6072cc57 (patch)
tree0dbe870615d5d490a3debe878e72c2658cabd2e4 /yavta.c
parent5444ca9d5fb255ea35fc60bf1cb27d29135cfbf3 (diff)
Set the v4l2_buffer::length field when queueing a buffer
Userspace buffers size needs to be passed to drivers on VIDIOC_QBUF. Set the v4l2_buffer::length field to the size of the allocated buffer before calling VIDIOC_QBUF. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Diffstat (limited to 'yavta.c')
-rw-r--r--yavta.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/yavta.c b/yavta.c
index 63d96e3..ae29bbe 100644
--- a/yavta.c
+++ b/yavta.c
@@ -385,6 +385,7 @@ static int video_queue_buffer(struct device *dev, int index)
buf.index = index;
buf.type = dev->type;
buf.memory = dev->memtype;
+ buf.length = dev->bufsize;
if (dev->memtype == V4L2_MEMORY_USERPTR)
buf.m.userptr = (unsigned long)dev->mem[index];