summaryrefslogtreecommitdiffstats
path: root/drivers/media/video/uvc/uvc_video.c
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2011-10-24 11:53:59 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2011-12-11 11:13:06 -0200
commit6998b6fb4b1c8f320adeee938d399c4d8dcc90e2 (patch)
tree2a8e7687fe177c526fb518f22aff497bb4fcd98c /drivers/media/video/uvc/uvc_video.c
parent3d95e932573c316ad56b8e2f283e26de0b9c891c (diff)
downloadblackbird-op-linux-6998b6fb4b1c8f320adeee938d399c4d8dcc90e2.tar.gz
blackbird-op-linux-6998b6fb4b1c8f320adeee938d399c4d8dcc90e2.zip
[media] uvcvideo: Use videobuf2-vmalloc
Replace the current video buffers queue implementation with videobuf2-vmalloc. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/uvc/uvc_video.c')
-rw-r--r--drivers/media/video/uvc/uvc_video.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/media/video/uvc/uvc_video.c b/drivers/media/video/uvc/uvc_video.c
index 00fe749c0cc0..2995f26ccae9 100644
--- a/drivers/media/video/uvc/uvc_video.c
+++ b/drivers/media/video/uvc/uvc_video.c
@@ -467,9 +467,10 @@ static int uvc_video_decode_start(struct uvc_streaming *stream,
else
ktime_get_real_ts(&ts);
- buf->buf.sequence = stream->sequence;
- buf->buf.timestamp.tv_sec = ts.tv_sec;
- buf->buf.timestamp.tv_usec = ts.tv_nsec / NSEC_PER_USEC;
+ buf->buf.v4l2_buf.sequence = stream->sequence;
+ buf->buf.v4l2_buf.timestamp.tv_sec = ts.tv_sec;
+ buf->buf.v4l2_buf.timestamp.tv_usec =
+ ts.tv_nsec / NSEC_PER_USEC;
/* TODO: Handle PTS and SCR. */
buf->state = UVC_BUF_STATE_ACTIVE;
@@ -728,7 +729,7 @@ static void uvc_video_encode_bulk(struct urb *urb, struct uvc_streaming *stream,
if (buf->bytesused == stream->queue.buf_used) {
stream->queue.buf_used = 0;
buf->state = UVC_BUF_STATE_READY;
- buf->buf.sequence = ++stream->sequence;
+ buf->buf.v4l2_buf.sequence = ++stream->sequence;
uvc_queue_next_buffer(&stream->queue, buf);
stream->last_fid ^= UVC_STREAM_FID;
}
OpenPOWER on IntegriCloud