summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMinas Harutyunyan <Minas.Harutyunyan@synopsys.com>2018-06-12 12:37:29 +0400
committerFelipe Balbi <felipe.balbi@linux.intel.com>2018-06-18 12:41:00 +0300
commit1ffba9058737af2ddeebc813faa8ea9b16bc892a (patch)
tree0c5ad5c1361ddc63820e4509b44b308861d415e3
parent3ec148ebe3112b40c9a2c0c543bcb0cd1a3abd43 (diff)
downloadlinux-stable-1ffba9058737af2ddeebc813faa8ea9b16bc892a.tar.gz
linux-stable-1ffba9058737af2ddeebc813faa8ea9b16bc892a.tar.bz2
linux-stable-1ffba9058737af2ddeebc813faa8ea9b16bc892a.zip
usb: dwc2: gadget: Fix issue in dwc2_gadget_start_isoc()
In case of requests queue is empty reset EP target_frame to initial value. This allow restarting ISOC traffic in case when function driver queued requests with interruptions. Tested-by: Zeng Tao <prime.zeng@hisilicon.com> Signed-off-by: Minas Harutyunyan <hminas@synopsys.com> Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
-rw-r--r--drivers/usb/dwc2/gadget.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/usb/dwc2/gadget.c b/drivers/usb/dwc2/gadget.c
index f0d9ccf1d665..bb499fea6100 100644
--- a/drivers/usb/dwc2/gadget.c
+++ b/drivers/usb/dwc2/gadget.c
@@ -884,6 +884,7 @@ static void dwc2_gadget_start_isoc_ddma(struct dwc2_hsotg_ep *hs_ep)
struct dwc2_dma_desc *desc;
if (list_empty(&hs_ep->queue)) {
+ hs_ep->target_frame = TARGET_FRAME_INITIAL;
dev_dbg(hsotg->dev, "%s: No requests in queue\n", __func__);
return;
}