diff options
author | Felipe Balbi <felipe.balbi@linux.intel.com> | 2016-08-10 12:35:30 +0300 |
---|---|---|
committer | Felipe Balbi <felipe.balbi@linux.intel.com> | 2016-08-10 14:15:57 +0300 |
commit | 7c705dfe2ebe731c8fd068623b6b4df2d3512c08 (patch) | |
tree | 86f0c2045319bdb5391181d1c8af665d4f67c50a | |
parent | e5b36ae2f851024d43c76e51f395d32ce8d769ce (diff) | |
download | linux-7c705dfe2ebe731c8fd068623b6b4df2d3512c08.tar.bz2 |
usb: dwc3: gadget: always cleanup all TRBs
If we stop earlier due to short packet, we will
not be able to giveback all TRBs.
Cc: <stable@vger.kernel.org>
Cc: Brian E Rogers <brian.e.rogers@intel.com>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
-rw-r--r-- | drivers/usb/dwc3/gadget.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c index 241f5c7b34bf..eb820e4ab49d 100644 --- a/drivers/usb/dwc3/gadget.c +++ b/drivers/usb/dwc3/gadget.c @@ -2028,7 +2028,7 @@ static int __dwc3_cleanup_done_trbs(struct dwc3 *dwc, struct dwc3_ep *dep, s_pkt = 1; } - if (s_pkt) + if (s_pkt && !chain) return 1; if ((event->status & DEPEVT_STATUS_LST) && (trb->ctrl & (DWC3_TRB_CTRL_LST | |