Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 124215
b: refs/heads/master
c: 23867b2
h: refs/heads/master
i:
  124213: c258c5b
  124211: fc4c303
  124207: 78d6b0a
v: v3
  • Loading branch information
Laurent Pinchart authored and Mauro Carvalho Chehab committed Dec 29, 2008
1 parent fc4e873 commit 084f0da
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 12 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 9bc6218dc1dc7bd421f3d141241c8e0e70c4e92b
refs/heads/master: 23867b2511140ae5693587d2b15badbcc632e3cc
7 changes: 0 additions & 7 deletions trunk/drivers/media/video/uvc/uvc_v4l2.c
Original file line number Diff line number Diff line change
Expand Up @@ -252,9 +252,6 @@ static int uvc_v4l2_set_format(struct uvc_video_device *video,
if (ret < 0)
return ret;

if ((ret = uvc_commit_video(video, &probe)) < 0)
return ret;

memcpy(&video->streaming->ctrl, &probe, sizeof probe);
video->streaming->cur_format = format;
video->streaming->cur_frame = frame;
Expand Down Expand Up @@ -315,10 +312,6 @@ static int uvc_v4l2_set_streamparm(struct uvc_video_device *video,
if ((ret = uvc_probe_video(video, &probe)) < 0)
return ret;

/* Commit the new settings. */
if ((ret = uvc_commit_video(video, &probe)) < 0)
return ret;

memcpy(&video->streaming->ctrl, &probe, sizeof probe);

/* Return the actual frame period. */
Expand Down
9 changes: 5 additions & 4 deletions trunk/drivers/media/video/uvc/uvc_video.c
Original file line number Diff line number Diff line change
Expand Up @@ -889,7 +889,7 @@ int uvc_video_resume(struct uvc_video_device *video)

video->frozen = 0;

if ((ret = uvc_set_video_ctrl(video, &video->streaming->ctrl, 0)) < 0) {
if ((ret = uvc_commit_video(video, &video->streaming->ctrl)) < 0) {
uvc_queue_enable(&video->queue, 0);
return ret;
}
Expand Down Expand Up @@ -970,11 +970,8 @@ int uvc_video_init(struct uvc_video_device *video)
break;
}

/* Commit the default settings. */
probe->bFormatIndex = format->index;
probe->bFrameIndex = frame->bFrameIndex;
if ((ret = uvc_set_video_ctrl(video, probe, 0)) < 0)
return ret;

video->streaming->cur_format = format;
video->streaming->cur_frame = frame;
Expand Down Expand Up @@ -1014,6 +1011,10 @@ int uvc_video_enable(struct uvc_video_device *video, int enable)
if ((ret = uvc_queue_enable(&video->queue, 1)) < 0)
return ret;

/* Commit the streaming parameters. */
if ((ret = uvc_commit_video(video, &video->streaming->ctrl)) < 0)
return ret;

return uvc_init_video(video, GFP_KERNEL);
}

0 comments on commit 084f0da

Please sign in to comment.