diff options
author | Vahram Aharonyan <vahrama@synopsys.com> | 2016-05-23 22:41:59 -0700 |
---|---|---|
committer | Felipe Balbi <felipe.balbi@linux.intel.com> | 2016-05-31 11:12:57 +0300 |
commit | 15186f1011b088432a10f435aa6e2df5ab177503 (patch) | |
tree | 74b5859e14e878e535229029b5bd83d24d8b1880 /drivers/usb/dwc2 | |
parent | 51da43b555ba19e0230ff5a5acc58eb0fffb6026 (diff) | |
download | linux-stable-15186f1011b088432a10f435aa6e2df5ab177503.tar.gz linux-stable-15186f1011b088432a10f435aa6e2df5ab177503.tar.bz2 linux-stable-15186f1011b088432a10f435aa6e2df5ab177503.zip |
usb: dwc2: gadget: Do not halt isochronous endpoints
Add a check in dwc2_hsotg_ep_sethalt() so that it does not halt
isochronous endpoints.
Signed-off-by: Vahram Aharonyan <vahrama@synopsys.com>
Signed-off-by: John Youn <johnyoun@synopsys.com>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
Diffstat (limited to 'drivers/usb/dwc2')
-rw-r--r-- | drivers/usb/dwc2/gadget.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/usb/dwc2/gadget.c b/drivers/usb/dwc2/gadget.c index e4e2a9031dee..26cf09d0fe3c 100644 --- a/drivers/usb/dwc2/gadget.c +++ b/drivers/usb/dwc2/gadget.c @@ -2974,6 +2974,11 @@ static int dwc2_hsotg_ep_sethalt(struct usb_ep *ep, int value, bool now) return 0; } + if (hs_ep->isochronous) { + dev_err(hs->dev, "%s is Isochronous Endpoint\n", ep->name); + return -EINVAL; + } + if (!now && value && !list_empty(&hs_ep->queue)) { dev_dbg(hs->dev, "%s request is pending, cannot halt\n", ep->name); |