Commit d7577b38 authored by Felipe Balbi's avatar Felipe Balbi

usb: gadget: function: uvc: conditionally dequeue

We shouldn't try to dequeue a NULL pointer.
Signed-off-by: default avatarFelipe Balbi <balbi@ti.com>
parent 7a608559
......@@ -352,6 +352,7 @@ int uvcg_video_enable(struct uvc_video *video, int enable)
if (!enable) {
for (i = 0; i < UVC_NUM_REQUESTS; ++i)
if (video->req[i])
usb_ep_dequeue(video->ep, video->req[i]);
uvc_video_free_requests(video);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment