summaryrefslogtreecommitdiffstats
path: root/drivers/media/parport
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2013-05-10 13:06:50 +0200
committerMauro Carvalho Chehab <mchehab@redhat.com>2013-05-27 14:30:19 +0200
commit6266a9d9b0e9824562c3c5604dd812d3befc72f1 (patch)
tree12664875ebbf2489595f9b7d0a55f263981d1809 /drivers/media/parport
parent[media] media: i2c: tvp7002: rearrange description of structure members (diff)
downloadlinux-6266a9d9b0e9824562c3c5604dd812d3befc72f1.tar.xz
linux-6266a9d9b0e9824562c3c5604dd812d3befc72f1.zip
[media] bw-qcam: fix timestamp handling
bw-qcam didn't set the timestamp and it didn't set q->timestamp_type. Tested-by: Borislav Petkov <bp@suse.de> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/parport')
-rw-r--r--drivers/media/parport/bw-qcam.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/media/parport/bw-qcam.c b/drivers/media/parport/bw-qcam.c
index 06231b85e1a9..d12bd33f39cb 100644
--- a/drivers/media/parport/bw-qcam.c
+++ b/drivers/media/parport/bw-qcam.c
@@ -687,6 +687,7 @@ static int buffer_finish(struct vb2_buffer *vb)
parport_release(qcam->pdev);
mutex_unlock(&qcam->lock);
+ v4l2_get_timestamp(&vb->v4l2_buf.timestamp);
if (len != size)
vb->state = VB2_BUF_STATE_ERROR;
vb2_set_plane_payload(vb, 0, len);
@@ -964,6 +965,7 @@ static struct qcam *qcam_init(struct parport *port)
q->drv_priv = qcam;
q->ops = &qcam_video_qops;
q->mem_ops = &vb2_vmalloc_memops;
+ q->timestamp_type = V4L2_BUF_FLAG_TIMESTAMP_MONOTONIC;
err = vb2_queue_init(q);
if (err < 0) {
v4l2_err(v4l2_dev, "couldn't init vb2_queue for %s.\n", port->name);