diff options
Diffstat (limited to 'drivers/media/video/uvc/uvc_video.c')
-rw-r--r-- | drivers/media/video/uvc/uvc_video.c | 9 |
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 e07bee98a00a..186ef9fad80b 100644 --- a/drivers/media/video/uvc/uvc_video.c +++ b/drivers/media/video/uvc/uvc_video.c | |||
@@ -889,7 +889,7 @@ int uvc_video_resume(struct uvc_video_device *video) | |||
889 | 889 | ||
890 | video->frozen = 0; | 890 | video->frozen = 0; |
891 | 891 | ||
892 | if ((ret = uvc_set_video_ctrl(video, &video->streaming->ctrl, 0)) < 0) { | 892 | if ((ret = uvc_commit_video(video, &video->streaming->ctrl)) < 0) { |
893 | uvc_queue_enable(&video->queue, 0); | 893 | uvc_queue_enable(&video->queue, 0); |
894 | return ret; | 894 | return ret; |
895 | } | 895 | } |
@@ -970,11 +970,8 @@ int uvc_video_init(struct uvc_video_device *video) | |||
970 | break; | 970 | break; |
971 | } | 971 | } |
972 | 972 | ||
973 | /* Commit the default settings. */ | ||
974 | probe->bFormatIndex = format->index; | 973 | probe->bFormatIndex = format->index; |
975 | probe->bFrameIndex = frame->bFrameIndex; | 974 | probe->bFrameIndex = frame->bFrameIndex; |
976 | if ((ret = uvc_set_video_ctrl(video, probe, 0)) < 0) | ||
977 | return ret; | ||
978 | 975 | ||
979 | video->streaming->cur_format = format; | 976 | video->streaming->cur_format = format; |
980 | video->streaming->cur_frame = frame; | 977 | video->streaming->cur_frame = frame; |
@@ -1014,6 +1011,10 @@ int uvc_video_enable(struct uvc_video_device *video, int enable) | |||
1014 | if ((ret = uvc_queue_enable(&video->queue, 1)) < 0) | 1011 | if ((ret = uvc_queue_enable(&video->queue, 1)) < 0) |
1015 | return ret; | 1012 | return ret; |
1016 | 1013 | ||
1014 | /* Commit the streaming parameters. */ | ||
1015 | if ((ret = uvc_commit_video(video, &video->streaming->ctrl)) < 0) | ||
1016 | return ret; | ||
1017 | |||
1017 | return uvc_init_video(video, GFP_KERNEL); | 1018 | return uvc_init_video(video, GFP_KERNEL); |
1018 | } | 1019 | } |
1019 | 1020 | ||