summaryrefslogtreecommitdiff
path: root/drivers/usb/gadget/function/uvc_video.c
diff options
context:
space:
mode:
authorJens Axboe <axboe@fb.com>2014-11-19 05:43:46 +0300
committerJens Axboe <axboe@fb.com>2014-11-19 05:43:46 +0300
commitb3521729769ec71567a2e32a38609f87e781e41b (patch)
tree66a8494968706420c3eb043caa5868702d440d18 /drivers/usb/gadget/function/uvc_video.c
parent139768895309c6c1d6913e909e9c9422f81a1640 (diff)
parentfc14f9c1272f62c3e8d01300f52467c0d9af50f9 (diff)
downloadlinux-b3521729769ec71567a2e32a38609f87e781e41b.tar.xz
Merge branch 'master' into for-3.19/drivers
Diffstat (limited to 'drivers/usb/gadget/function/uvc_video.c')
-rw-r--r--drivers/usb/gadget/function/uvc_video.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/usb/gadget/function/uvc_video.c b/drivers/usb/gadget/function/uvc_video.c
index c3e1f27dbbef..9cb86bc1a9a5 100644
--- a/drivers/usb/gadget/function/uvc_video.c
+++ b/drivers/usb/gadget/function/uvc_video.c
@@ -352,7 +352,8 @@ int uvcg_video_enable(struct uvc_video *video, int enable)
if (!enable) {
for (i = 0; i < UVC_NUM_REQUESTS; ++i)
- usb_ep_dequeue(video->ep, video->req[i]);
+ if (video->req[i])
+ usb_ep_dequeue(video->ep, video->req[i]);
uvc_video_free_requests(video);
uvcg_queue_enable(&video->queue, 0);