aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/usbvision
diff options
context:
space:
mode:
authorTrent Piepho <xyzzy@speakeasy.org>2009-03-03 20:44:45 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-03-30 12:43:04 -0300
commit9cfb6a3f1b16e82fab97831265858aa2d1983883 (patch)
treee5b25c018495f3b7361af9dfdfb3ec588696ac26 /drivers/media/video/usbvision
parent86b5aeacabb4451655c528c41d45ca05b753f72c (diff)
downloadkernel_samsung_smdk4412-9cfb6a3f1b16e82fab97831265858aa2d1983883.zip
kernel_samsung_smdk4412-9cfb6a3f1b16e82fab97831265858aa2d1983883.tar.gz
kernel_samsung_smdk4412-9cfb6a3f1b16e82fab97831265858aa2d1983883.tar.bz2
V4L/DVB (10794): v4l2: Move code to zero querybuf output struct to v4l2_ioctl
For VIDIOC_QUERYBUF only the first two fields, size and type, are used as input. The rest can be filled in by the driver as output. Most drivers do not actually use all the field and unused ones should be zeroed out. Some drivers have code to do this and some drivers should but don't. So put some zero out code in v4l2_ioctl so that all drivers using that system get it. The drivers that have zeroing code get that code removed. Some drivers checked that the type field was valid, but v4l2_ioctl already does this so those checks can be removed as well. Signed-off-by: Trent Piepho <xyzzy@speakeasy.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/usbvision')
-rw-r--r--drivers/media/video/usbvision/usbvision-video.c3
1 files changed, 0 insertions, 3 deletions
diff --git a/drivers/media/video/usbvision/usbvision-video.c b/drivers/media/video/usbvision/usbvision-video.c
index 33d79a5..863fcb31 100644
--- a/drivers/media/video/usbvision/usbvision-video.c
+++ b/drivers/media/video/usbvision/usbvision-video.c
@@ -788,9 +788,6 @@ static int vidioc_querybuf (struct file *file,
/* FIXME : must control
that buffers are mapped (VIDIOC_REQBUFS has been called) */
- if(vb->type != V4L2_CAP_VIDEO_CAPTURE) {
- return -EINVAL;
- }
if(vb->index>=usbvision->num_frames) {
return -EINVAL;
}