usb: dwc3: gadget: Do link recovery for SS and SSP
authorThinh Nguyen <Thinh.Nguyen@synopsys.com>
Sat, 1 Feb 2020 00:25:50 +0000 (16:25 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 2 May 2020 06:48:42 +0000 (08:48 +0200)
commit7067a62563d2a8d3c75d00268bc539a30fcdc64a
tree09883a84c66c3e678b01e23beac357893b5c487d
parenta74a5435a6103134862549d0eaee6a85ef383b7e
usb: dwc3: gadget: Do link recovery for SS and SSP

commit d0550cd20e52558ecf6847a0f96ebd5d944c17e4 upstream.

The controller always supports link recovery for device in SS and SSP.
Remove the speed limit check. Also, when the device is in RESUME or
RESET state, it means the controller received the resume/reset request.
The driver must send the link recovery to acknowledge the request. They
are valid states for the driver to send link recovery.

Fixes: 72246da40f37 ("usb: Introduce DesignWare USB3 DRD Driver")
Fixes: ee5cd41c9117 ("usb: dwc3: Update speed checks for SuperSpeedPlus")
Signed-off-by: Thinh Nguyen <thinhn@synopsys.com>
Signed-off-by: Felipe Balbi <balbi@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/dwc3/gadget.c