diff options
author | Felipe Balbi <balbi@ti.com> | 2012-05-24 10:30:01 +0300 |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2012-06-03 23:08:25 +0300 |
commit | c4430a26948b84c0d820e83f8c640229f960d3b6 (patch) | |
tree | 7013c5a333e7200cfe3e59b56558e3a13bd693ac /drivers/usb/dwc3 | |
parent | fcc023c726b5879d8f3f0f0f48c45d09055272c4 (diff) |
usb: dwc3: gadget: disable U1/U2 on disconnect
If we get a disconnect IRQ, we should take
the core out of low power mode so we can
reconnect afterwards.
Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/dwc3')
-rw-r--r-- | drivers/usb/dwc3/gadget.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c index 867c476853ec..054ee5ec5c13 100644 --- a/drivers/usb/dwc3/gadget.c +++ b/drivers/usb/dwc3/gadget.c @@ -1906,11 +1906,9 @@ static void dwc3_clear_stall_all_ep(struct dwc3 *dwc) static void dwc3_gadget_disconnect_interrupt(struct dwc3 *dwc) { + int reg; + dev_vdbg(dwc->dev, "%s\n", __func__); -#if 0 - XXX - U1/U2 is powersave optimization. Skip it for now. Anyway we need to - enable it before we can disable it. reg = dwc3_readl(dwc->regs, DWC3_DCTL); reg &= ~DWC3_DCTL_INITU1ENA; @@ -1918,7 +1916,6 @@ static void dwc3_gadget_disconnect_interrupt(struct dwc3 *dwc) reg &= ~DWC3_DCTL_INITU2ENA; dwc3_writel(dwc->regs, DWC3_DCTL, reg); -#endif dwc3_stop_active_transfers(dwc); dwc3_disconnect_gadget(dwc); |