diff options
author | Felipe Balbi <felipe.balbi@linux.intel.com> | 2016-05-13 10:19:42 +0300 |
---|---|---|
committer | Felipe Balbi <felipe.balbi@linux.intel.com> | 2016-06-20 12:30:06 +0300 |
commit | 6b74289937f624439c87135cfabb3deb2955fb53 (patch) | |
tree | 33b8048dc63f61713f19dd880700fab10b2333de /drivers/usb/dwc3/gadget.c | |
parent | b43bba96b9036e42b2c2c71ee15e1f77b0b37aec (diff) | |
download | lwn-6b74289937f624439c87135cfabb3deb2955fb53.tar.gz lwn-6b74289937f624439c87135cfabb3deb2955fb53.zip |
usb: dwc3: gadget: return 0 if we try to Wakeup in superspeed
Instead of returning -EINVAL when someone calls
__dwc3_gadget_wakeup() in speeds > highspeed, let's
return 0. There are no problems for the driver for
calling it in superspeed as we cleanly just return.
This avoids an annoying WARN_ONCE() always
triggering during superspeed enumeration with LPM
enabled.
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
Diffstat (limited to 'drivers/usb/dwc3/gadget.c')
-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 79d1882f1908..4c9fe7b55100 100644 --- a/drivers/usb/dwc3/gadget.c +++ b/drivers/usb/dwc3/gadget.c @@ -1431,7 +1431,7 @@ static int __dwc3_gadget_wakeup(struct dwc3 *dwc) if ((speed == DWC3_DSTS_SUPERSPEED) || (speed == DWC3_DSTS_SUPERSPEED_PLUS)) { dwc3_trace(trace_dwc3_gadget, "no wakeup on SuperSpeed\n"); - return -EINVAL; + return 0; } link_state = DWC3_DSTS_USBLNKST(reg); |