[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <1548064976-30196-1-git-send-email-prime.zeng@hisilicon.com>
Date: Mon, 21 Jan 2019 18:02:56 +0800
From: Zeng Tao <prime.zeng@...ilicon.com>
To: <felipe.balbi@...ux.intel.com>
CC: Zeng Tao <prime.zeng@...ilicon.com>,
Felipe Balbi <balbi@...nel.org>,
"Greg Kroah-Hartman" <gregkh@...uxfoundation.org>,
<linux-usb@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: [PATCH] usb: dwc3: gadget: issue a stop command for ISOC endpoint
For ISOC transfers, if there is no available data for a period, we need
to stop the transfer by issue a stop command, otherwise, all the
upcoming transfers will started by update transfer command, and will be
dropped with MISS ISOC errors.
Signed-off-by: Zeng Tao <prime.zeng@...ilicon.com>
---
drivers/usb/dwc3/gadget.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c
index e18c2a2..58e71ba 100644
--- a/drivers/usb/dwc3/gadget.c
+++ b/drivers/usb/dwc3/gadget.c
@@ -2500,6 +2500,10 @@ static void dwc3_gadget_endpoint_transfer_in_progress(struct dwc3_ep *dep,
stop = true;
}
+ if (list_empty(&dep->started_list) &&
+ (usb_endpoint_xfer_isoc(dep->endpoint.desc)))
+ stop = true;
+
dwc3_gadget_ep_cleanup_completed_requests(dep, event, status);
if (stop) {
--
2.7.4
Powered by blists - more mailing lists