summaryrefslogtreecommitdiff
path: root/drivers/media/usb/uvc/uvc_video.c
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2012-08-29 01:38:58 +0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2012-11-28 16:27:49 +0400
commit815adc465de9c8cd1967d0d9d538ed30925423a0 (patch)
tree5a21ecf655f3ce9fb0e16182e98bdbb7f5f4da78 /drivers/media/usb/uvc/uvc_video.c
parent30ecb936cbcd83e3735625ac63e1b4466546f5fe (diff)
downloadlinux-815adc465de9c8cd1967d0d9d538ed30925423a0.tar.xz
[media] uvcvideo: Don't fail when an unsupported format is requested
Return the default format in that case. This issue was found by the v4l2-compliance tool. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/usb/uvc/uvc_video.c')
-rw-r--r--drivers/media/usb/uvc/uvc_video.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/media/usb/uvc/uvc_video.c b/drivers/media/usb/uvc/uvc_video.c
index 57c3076a4625..3394c3432011 100644
--- a/drivers/media/usb/uvc/uvc_video.c
+++ b/drivers/media/usb/uvc/uvc_video.c
@@ -1812,6 +1812,7 @@ int uvc_video_init(struct uvc_streaming *stream)
probe->bFormatIndex = format->index;
probe->bFrameIndex = frame->bFrameIndex;
+ stream->def_format = format;
stream->cur_format = format;
stream->cur_frame = frame;