Skip to content

Commit

Permalink
usb: gadget: uvc: fix dropped frame after missed isoc
Browse files Browse the repository at this point in the history
With the re-use of the previous completion status in 0d1c407
("usb: dwc3: gadget: Return proper request status") it could be possible
that the next frame would also get dropped if the current frame has a
missed isoc error. Ensure that an interrupt is requested for the start
of a new frame.

Fixes: fc78941 ("usb: gadget: uvc: decrease the interrupt load to a quarter")
Cc: <stable@vger.kernel.org>
Signed-off-by: Dan Vacura <w36195@motorola.com>
Link: https://lore.kernel.org/r/20221018215044.765044-2-w36195@motorola.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Dan Vacura authored and Greg Kroah-Hartman committed Oct 22, 2022
1 parent 4db0fbb commit 8e8e923
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/usb/gadget/function/uvc_video.c
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,8 @@ static void uvcg_video_pump(struct work_struct *work)

/* Endpoint now owns the request */
req = NULL;
video->req_int_count++;
if (buf->state != UVC_BUF_STATE_DONE)
video->req_int_count++;
}

if (!req)
Expand Down

0 comments on commit 8e8e923

Please sign in to comment.