usb: musb: fix tx fifo flush handling again
authorBin Liu <b-liu@ti.com>
Tue, 25 Jul 2017 14:31:34 +0000 (09:31 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 16 Aug 2017 20:35:30 +0000 (13:35 -0700)
commit98b91bfa5e478b9bf332f9f149b1c25ffd58f877
tree85fbfe9df6a6decacea693cafeeb9a3b54dae19c
parent7af1cd4b40aaa8b90d7f564786339ff0e63e06e8
usb: musb: fix tx fifo flush handling again

commit 45d73860530a14c608f410b91c6c341777bfa85d upstream.

commit 68fe05e2a451 ("usb: musb: fix tx fifo flush handling") drops the
1ms delay trying to solve the long disconnect time issue when
application queued many tx urbs. However, the 1ms delay is needed for
some use cases, for example, without the delay, reconnecting AR9271 WIFI
dongle no longer works if the connection is dropped from the AP.

So let's add back the 1ms delay in musb_h_tx_flush_fifo(), and solve the
long disconnect time problem with a separate patch for
usb_hcd_flush_endpoint().

Signed-off-by: Bin Liu <b-liu@ti.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/musb/musb_host.c