]> www.infradead.org Git - users/dwmw2/linux.git/commitdiff
xhci: Turn NEC specific quirk for handling Stop Endpoint errors generic
authorMathias Nyman <mathias.nyman@linux.intel.com>
Tue, 17 Dec 2024 10:21:21 +0000 (12:21 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 17 Dec 2024 10:59:09 +0000 (11:59 +0100)
xHC hosts from several vendors have the same issue where endpoints start
so slowly that a later queued 'Stop Endpoint' command may complete before
endpoint is up and running.

The 'Stop Endpoint' command fails with context state error as the endpoint
still appears as  stopped.

See commit 42b758137601 ("usb: xhci: Limit Stop Endpoint retries") for
details

CC: stable@vger.kernel.org
Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
Link: https://lore.kernel.org/r/20241217102122.2316814-2-mathias.nyman@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/host/xhci-ring.c

index 4cf5363875c704d9eb2ca18ca4b815716c6029ed..09b05a62375e0142e73a9ac553c6010570f95f5a 100644 (file)
@@ -1199,8 +1199,6 @@ static void xhci_handle_cmd_stop_ep(struct xhci_hcd *xhci, int slot_id,
                         * Keep retrying until the EP starts and stops again, on
                         * chips where this is known to help. Wait for 100ms.
                         */
-                       if (!(xhci->quirks & XHCI_NEC_HOST))
-                               break;
                        if (time_is_before_jiffies(ep->stop_time + msecs_to_jiffies(100)))
                                break;
                        fallthrough;