]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
drop xhci patch that broke many builds
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Sep 2025 08:27:50 +0000 (10:27 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Sep 2025 08:27:50 +0000 (10:27 +0200)
queue-5.10/series
queue-5.10/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch [deleted file]
queue-5.15/series
queue-5.15/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch [deleted file]
queue-6.1/series
queue-6.1/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch [deleted file]
queue-6.12/series
queue-6.12/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch [deleted file]
queue-6.6/series
queue-6.6/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch [deleted file]

index a9833ca5a9f730ee611c6a688e7bae82c8dadcd8..669725e58f130b03662802130de49fa1a12790b7 100644 (file)
@@ -39,6 +39,5 @@ i40e-fix-irq-freeing-in-i40e_vsi_request_irq_msix-er.patch
 can-j1939-j1939_sk_bind-call-j1939_priv_put-immediat.patch
 can-j1939-j1939_local_ecu_get-undo-increment-when-j1.patch
 dmaengine-ti-edma-fix-memory-allocation-size-for-que.patch
-xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch
 dmaengine-qcom-bam_dma-fix-dt-error-handling-for-num-channels-ees.patch
 phy-ti-pipe3-fix-device-leak-at-unbind.patch
diff --git a/queue-5.10/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch b/queue-5.10/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch
deleted file mode 100644 (file)
index 228d493..0000000
+++ /dev/null
@@ -1,86 +0,0 @@
-From a5c98e8b1398534ae1feb6e95e2d3ee5215538ed Mon Sep 17 00:00:00 2001
-From: Mathias Nyman <mathias.nyman@linux.intel.com>
-Date: Tue, 2 Sep 2025 13:53:05 +0300
-Subject: xhci: dbc: Fix full DbC transfer ring after several reconnects
-
-From: Mathias Nyman <mathias.nyman@linux.intel.com>
-
-commit a5c98e8b1398534ae1feb6e95e2d3ee5215538ed upstream.
-
-Pending requests will be flushed on disconnect, and the corresponding
-TRBs will be turned into No-op TRBs, which are ignored by the xHC
-controller once it starts processing the ring.
-
-If the USB debug cable repeatedly disconnects before ring is started
-then the ring will eventually be filled with No-op TRBs.
-No new transfers can be queued when the ring is full, and driver will
-print the following error message:
-
-    "xhci_hcd 0000:00:14.0: failed to queue trbs"
-
-This is a normal case for 'in' transfers where TRBs are always enqueued
-in advance, ready to take on incoming data. If no data arrives, and
-device is disconnected, then ring dequeue will remain at beginning of
-the ring while enqueue points to first free TRB after last cancelled
-No-op TRB.
-s
-Solve this by reinitializing the rings when the debug cable disconnects
-and DbC is leaving the configured state.
-Clear the whole ring buffer and set enqueue and dequeue to the beginning
-of ring, and set cycle bit to its initial state.
-
-Cc: stable@vger.kernel.org
-Fixes: dfba2174dc42 ("usb: xhci: Add DbC support in xHCI driver")
-Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
-Link: https://lore.kernel.org/r/20250902105306.877476-3-mathias.nyman@linux.intel.com
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- drivers/usb/host/xhci-dbgcap.c |   23 +++++++++++++++++++++--
- 1 file changed, 21 insertions(+), 2 deletions(-)
-
---- a/drivers/usb/host/xhci-dbgcap.c
-+++ b/drivers/usb/host/xhci-dbgcap.c
-@@ -421,6 +421,25 @@ dbc_alloc_ctx(struct device *dev, gfp_t
-       return ctx;
- }
-+static int xhci_dbc_reinit_ep_rings(struct xhci_dbc *dbc)
-+{
-+      struct xhci_ring *in_ring = dbc->eps[BULK_IN].ring;
-+      struct xhci_ring *out_ring = dbc->eps[BULK_OUT].ring;
-+
-+      if (!in_ring || !out_ring || !dbc->ctx) {
-+              dev_warn(dbc->dev, "Can't re-init unallocated endpoints\n");
-+              return -ENODEV;
-+      }
-+
-+      xhci_dbc_ring_init(in_ring);
-+      xhci_dbc_ring_init(out_ring);
-+
-+      /* set ep context enqueue, dequeue, and cycle to initial values */
-+      xhci_dbc_init_ep_contexts(dbc);
-+
-+      return 0;
-+}
-+
- static struct xhci_ring *
- xhci_dbc_ring_alloc(struct device *dev, enum xhci_ring_type type, gfp_t flags)
- {
-@@ -850,7 +869,7 @@ static enum evtreturn xhci_dbc_do_handle
-                       dev_info(dbc->dev, "DbC cable unplugged\n");
-                       dbc->state = DS_ENABLED;
-                       xhci_dbc_flush_requests(dbc);
--
-+                      xhci_dbc_reinit_ep_rings(dbc);
-                       return EVT_DISC;
-               }
-@@ -860,7 +879,7 @@ static enum evtreturn xhci_dbc_do_handle
-                       writel(portsc, &dbc->regs->portsc);
-                       dbc->state = DS_ENABLED;
-                       xhci_dbc_flush_requests(dbc);
--
-+                      xhci_dbc_reinit_ep_rings(dbc);
-                       return EVT_DISC;
-               }
index 8828c88f168fd441c64dadf37abc15652601f004..53bb935351f782186e11e0171374affe9b240bab 100644 (file)
@@ -55,7 +55,6 @@ regulator-sy7636a-fix-lifecycle-of-power-good-gpio.patch
 hrtimer-remove-unused-function.patch
 hrtimer-rename-__hrtimer_hres_active-to-hrtimer_hres.patch
 hrtimers-unconditionally-update-target-cpu-base-afte.patch
-xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch
 dmaengine-qcom-bam_dma-fix-dt-error-handling-for-num-channels-ees.patch
 phy-tegra-xusb-fix-device-and-of-node-leak-at-probe.patch
 phy-ti-pipe3-fix-device-leak-at-unbind.patch
diff --git a/queue-5.15/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch b/queue-5.15/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch
deleted file mode 100644 (file)
index 228d493..0000000
+++ /dev/null
@@ -1,86 +0,0 @@
-From a5c98e8b1398534ae1feb6e95e2d3ee5215538ed Mon Sep 17 00:00:00 2001
-From: Mathias Nyman <mathias.nyman@linux.intel.com>
-Date: Tue, 2 Sep 2025 13:53:05 +0300
-Subject: xhci: dbc: Fix full DbC transfer ring after several reconnects
-
-From: Mathias Nyman <mathias.nyman@linux.intel.com>
-
-commit a5c98e8b1398534ae1feb6e95e2d3ee5215538ed upstream.
-
-Pending requests will be flushed on disconnect, and the corresponding
-TRBs will be turned into No-op TRBs, which are ignored by the xHC
-controller once it starts processing the ring.
-
-If the USB debug cable repeatedly disconnects before ring is started
-then the ring will eventually be filled with No-op TRBs.
-No new transfers can be queued when the ring is full, and driver will
-print the following error message:
-
-    "xhci_hcd 0000:00:14.0: failed to queue trbs"
-
-This is a normal case for 'in' transfers where TRBs are always enqueued
-in advance, ready to take on incoming data. If no data arrives, and
-device is disconnected, then ring dequeue will remain at beginning of
-the ring while enqueue points to first free TRB after last cancelled
-No-op TRB.
-s
-Solve this by reinitializing the rings when the debug cable disconnects
-and DbC is leaving the configured state.
-Clear the whole ring buffer and set enqueue and dequeue to the beginning
-of ring, and set cycle bit to its initial state.
-
-Cc: stable@vger.kernel.org
-Fixes: dfba2174dc42 ("usb: xhci: Add DbC support in xHCI driver")
-Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
-Link: https://lore.kernel.org/r/20250902105306.877476-3-mathias.nyman@linux.intel.com
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- drivers/usb/host/xhci-dbgcap.c |   23 +++++++++++++++++++++--
- 1 file changed, 21 insertions(+), 2 deletions(-)
-
---- a/drivers/usb/host/xhci-dbgcap.c
-+++ b/drivers/usb/host/xhci-dbgcap.c
-@@ -421,6 +421,25 @@ dbc_alloc_ctx(struct device *dev, gfp_t
-       return ctx;
- }
-+static int xhci_dbc_reinit_ep_rings(struct xhci_dbc *dbc)
-+{
-+      struct xhci_ring *in_ring = dbc->eps[BULK_IN].ring;
-+      struct xhci_ring *out_ring = dbc->eps[BULK_OUT].ring;
-+
-+      if (!in_ring || !out_ring || !dbc->ctx) {
-+              dev_warn(dbc->dev, "Can't re-init unallocated endpoints\n");
-+              return -ENODEV;
-+      }
-+
-+      xhci_dbc_ring_init(in_ring);
-+      xhci_dbc_ring_init(out_ring);
-+
-+      /* set ep context enqueue, dequeue, and cycle to initial values */
-+      xhci_dbc_init_ep_contexts(dbc);
-+
-+      return 0;
-+}
-+
- static struct xhci_ring *
- xhci_dbc_ring_alloc(struct device *dev, enum xhci_ring_type type, gfp_t flags)
- {
-@@ -850,7 +869,7 @@ static enum evtreturn xhci_dbc_do_handle
-                       dev_info(dbc->dev, "DbC cable unplugged\n");
-                       dbc->state = DS_ENABLED;
-                       xhci_dbc_flush_requests(dbc);
--
-+                      xhci_dbc_reinit_ep_rings(dbc);
-                       return EVT_DISC;
-               }
-@@ -860,7 +879,7 @@ static enum evtreturn xhci_dbc_do_handle
-                       writel(portsc, &dbc->regs->portsc);
-                       dbc->state = DS_ENABLED;
-                       xhci_dbc_flush_requests(dbc);
--
-+                      xhci_dbc_reinit_ep_rings(dbc);
-                       return EVT_DISC;
-               }
index 0bcdb96171b65c91c793748dcd320f0085ff208e..629689fd991b12676c4d8d5ddee828e054213a3a 100644 (file)
@@ -67,7 +67,6 @@ regulator-sy7636a-fix-lifecycle-of-power-good-gpio.patch
 hrtimer-remove-unused-function.patch
 hrtimer-rename-__hrtimer_hres_active-to-hrtimer_hres.patch
 hrtimers-unconditionally-update-target-cpu-base-afte.patch
-xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch
 usb-gadget-dummy-hcd-fix-locking-bug-in-rt-enabled-kernels.patch
 dmaengine-qcom-bam_dma-fix-dt-error-handling-for-num-channels-ees.patch
 dmaengine-dw-dmamux-fix-device-reference-leak-in-rzn1_dmamux_route_allocate.patch
diff --git a/queue-6.1/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch b/queue-6.1/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch
deleted file mode 100644 (file)
index 228d493..0000000
+++ /dev/null
@@ -1,86 +0,0 @@
-From a5c98e8b1398534ae1feb6e95e2d3ee5215538ed Mon Sep 17 00:00:00 2001
-From: Mathias Nyman <mathias.nyman@linux.intel.com>
-Date: Tue, 2 Sep 2025 13:53:05 +0300
-Subject: xhci: dbc: Fix full DbC transfer ring after several reconnects
-
-From: Mathias Nyman <mathias.nyman@linux.intel.com>
-
-commit a5c98e8b1398534ae1feb6e95e2d3ee5215538ed upstream.
-
-Pending requests will be flushed on disconnect, and the corresponding
-TRBs will be turned into No-op TRBs, which are ignored by the xHC
-controller once it starts processing the ring.
-
-If the USB debug cable repeatedly disconnects before ring is started
-then the ring will eventually be filled with No-op TRBs.
-No new transfers can be queued when the ring is full, and driver will
-print the following error message:
-
-    "xhci_hcd 0000:00:14.0: failed to queue trbs"
-
-This is a normal case for 'in' transfers where TRBs are always enqueued
-in advance, ready to take on incoming data. If no data arrives, and
-device is disconnected, then ring dequeue will remain at beginning of
-the ring while enqueue points to first free TRB after last cancelled
-No-op TRB.
-s
-Solve this by reinitializing the rings when the debug cable disconnects
-and DbC is leaving the configured state.
-Clear the whole ring buffer and set enqueue and dequeue to the beginning
-of ring, and set cycle bit to its initial state.
-
-Cc: stable@vger.kernel.org
-Fixes: dfba2174dc42 ("usb: xhci: Add DbC support in xHCI driver")
-Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
-Link: https://lore.kernel.org/r/20250902105306.877476-3-mathias.nyman@linux.intel.com
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- drivers/usb/host/xhci-dbgcap.c |   23 +++++++++++++++++++++--
- 1 file changed, 21 insertions(+), 2 deletions(-)
-
---- a/drivers/usb/host/xhci-dbgcap.c
-+++ b/drivers/usb/host/xhci-dbgcap.c
-@@ -421,6 +421,25 @@ dbc_alloc_ctx(struct device *dev, gfp_t
-       return ctx;
- }
-+static int xhci_dbc_reinit_ep_rings(struct xhci_dbc *dbc)
-+{
-+      struct xhci_ring *in_ring = dbc->eps[BULK_IN].ring;
-+      struct xhci_ring *out_ring = dbc->eps[BULK_OUT].ring;
-+
-+      if (!in_ring || !out_ring || !dbc->ctx) {
-+              dev_warn(dbc->dev, "Can't re-init unallocated endpoints\n");
-+              return -ENODEV;
-+      }
-+
-+      xhci_dbc_ring_init(in_ring);
-+      xhci_dbc_ring_init(out_ring);
-+
-+      /* set ep context enqueue, dequeue, and cycle to initial values */
-+      xhci_dbc_init_ep_contexts(dbc);
-+
-+      return 0;
-+}
-+
- static struct xhci_ring *
- xhci_dbc_ring_alloc(struct device *dev, enum xhci_ring_type type, gfp_t flags)
- {
-@@ -850,7 +869,7 @@ static enum evtreturn xhci_dbc_do_handle
-                       dev_info(dbc->dev, "DbC cable unplugged\n");
-                       dbc->state = DS_ENABLED;
-                       xhci_dbc_flush_requests(dbc);
--
-+                      xhci_dbc_reinit_ep_rings(dbc);
-                       return EVT_DISC;
-               }
-@@ -860,7 +879,7 @@ static enum evtreturn xhci_dbc_do_handle
-                       writel(portsc, &dbc->regs->portsc);
-                       dbc->state = DS_ENABLED;
-                       xhci_dbc_flush_requests(dbc);
--
-+                      xhci_dbc_reinit_ep_rings(dbc);
-                       return EVT_DISC;
-               }
index b513995f39238ac55262b3af02c0991660ed7ab0..7582ebf96a92d56c22ee71c4025981967c483274 100644 (file)
@@ -124,7 +124,6 @@ dmaengine-idxd-fix-double-free-in-idxd_setup_wqs.patch
 dmaengine-ti-edma-fix-memory-allocation-size-for-que.patch
 regulator-sy7636a-fix-lifecycle-of-power-good-gpio.patch
 risc-v-remove-unnecessary-include-from-compat.h.patch
-xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch
 xhci-fix-memory-leak-regression-when-freeing-xhci-vdev-devices-depth-first.patch
 usb-gadget-dummy-hcd-fix-locking-bug-in-rt-enabled-kernels.patch
 usb-typec-tcpm-properly-deliver-cable-vdms-to-altmode-drivers.patch
diff --git a/queue-6.12/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch b/queue-6.12/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch
deleted file mode 100644 (file)
index 9475932..0000000
+++ /dev/null
@@ -1,86 +0,0 @@
-From a5c98e8b1398534ae1feb6e95e2d3ee5215538ed Mon Sep 17 00:00:00 2001
-From: Mathias Nyman <mathias.nyman@linux.intel.com>
-Date: Tue, 2 Sep 2025 13:53:05 +0300
-Subject: xhci: dbc: Fix full DbC transfer ring after several reconnects
-
-From: Mathias Nyman <mathias.nyman@linux.intel.com>
-
-commit a5c98e8b1398534ae1feb6e95e2d3ee5215538ed upstream.
-
-Pending requests will be flushed on disconnect, and the corresponding
-TRBs will be turned into No-op TRBs, which are ignored by the xHC
-controller once it starts processing the ring.
-
-If the USB debug cable repeatedly disconnects before ring is started
-then the ring will eventually be filled with No-op TRBs.
-No new transfers can be queued when the ring is full, and driver will
-print the following error message:
-
-    "xhci_hcd 0000:00:14.0: failed to queue trbs"
-
-This is a normal case for 'in' transfers where TRBs are always enqueued
-in advance, ready to take on incoming data. If no data arrives, and
-device is disconnected, then ring dequeue will remain at beginning of
-the ring while enqueue points to first free TRB after last cancelled
-No-op TRB.
-s
-Solve this by reinitializing the rings when the debug cable disconnects
-and DbC is leaving the configured state.
-Clear the whole ring buffer and set enqueue and dequeue to the beginning
-of ring, and set cycle bit to its initial state.
-
-Cc: stable@vger.kernel.org
-Fixes: dfba2174dc42 ("usb: xhci: Add DbC support in xHCI driver")
-Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
-Link: https://lore.kernel.org/r/20250902105306.877476-3-mathias.nyman@linux.intel.com
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- drivers/usb/host/xhci-dbgcap.c |   23 +++++++++++++++++++++--
- 1 file changed, 21 insertions(+), 2 deletions(-)
-
---- a/drivers/usb/host/xhci-dbgcap.c
-+++ b/drivers/usb/host/xhci-dbgcap.c
-@@ -435,6 +435,25 @@ dbc_alloc_ctx(struct device *dev, gfp_t
-       return ctx;
- }
-+static int xhci_dbc_reinit_ep_rings(struct xhci_dbc *dbc)
-+{
-+      struct xhci_ring *in_ring = dbc->eps[BULK_IN].ring;
-+      struct xhci_ring *out_ring = dbc->eps[BULK_OUT].ring;
-+
-+      if (!in_ring || !out_ring || !dbc->ctx) {
-+              dev_warn(dbc->dev, "Can't re-init unallocated endpoints\n");
-+              return -ENODEV;
-+      }
-+
-+      xhci_dbc_ring_init(in_ring);
-+      xhci_dbc_ring_init(out_ring);
-+
-+      /* set ep context enqueue, dequeue, and cycle to initial values */
-+      xhci_dbc_init_ep_contexts(dbc);
-+
-+      return 0;
-+}
-+
- static struct xhci_ring *
- xhci_dbc_ring_alloc(struct device *dev, enum xhci_ring_type type, gfp_t flags)
- {
-@@ -863,7 +882,7 @@ static enum evtreturn xhci_dbc_do_handle
-                       dev_info(dbc->dev, "DbC cable unplugged\n");
-                       dbc->state = DS_ENABLED;
-                       xhci_dbc_flush_requests(dbc);
--
-+                      xhci_dbc_reinit_ep_rings(dbc);
-                       return EVT_DISC;
-               }
-@@ -873,7 +892,7 @@ static enum evtreturn xhci_dbc_do_handle
-                       writel(portsc, &dbc->regs->portsc);
-                       dbc->state = DS_ENABLED;
-                       xhci_dbc_flush_requests(dbc);
--
-+                      xhci_dbc_reinit_ep_rings(dbc);
-                       return EVT_DISC;
-               }
index 0c4b3be2d165f769f17faed2efe014404cbf8d46..c539ebc52f06dbc2cee935e164ee380edceb5866 100644 (file)
@@ -87,7 +87,6 @@ hrtimer-remove-unused-function.patch
 hrtimer-rename-__hrtimer_hres_active-to-hrtimer_hres.patch
 hrtimers-unconditionally-update-target-cpu-base-afte.patch
 risc-v-remove-unnecessary-include-from-compat.h.patch
-xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch
 xhci-fix-memory-leak-regression-when-freeing-xhci-vdev-devices-depth-first.patch
 usb-gadget-dummy-hcd-fix-locking-bug-in-rt-enabled-kernels.patch
 usb-gadget-midi2-fix-missing-ump-group-attributes-initialization.patch
diff --git a/queue-6.6/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch b/queue-6.6/xhci-dbc-fix-full-dbc-transfer-ring-after-several-reconnects.patch
deleted file mode 100644 (file)
index 228d493..0000000
+++ /dev/null
@@ -1,86 +0,0 @@
-From a5c98e8b1398534ae1feb6e95e2d3ee5215538ed Mon Sep 17 00:00:00 2001
-From: Mathias Nyman <mathias.nyman@linux.intel.com>
-Date: Tue, 2 Sep 2025 13:53:05 +0300
-Subject: xhci: dbc: Fix full DbC transfer ring after several reconnects
-
-From: Mathias Nyman <mathias.nyman@linux.intel.com>
-
-commit a5c98e8b1398534ae1feb6e95e2d3ee5215538ed upstream.
-
-Pending requests will be flushed on disconnect, and the corresponding
-TRBs will be turned into No-op TRBs, which are ignored by the xHC
-controller once it starts processing the ring.
-
-If the USB debug cable repeatedly disconnects before ring is started
-then the ring will eventually be filled with No-op TRBs.
-No new transfers can be queued when the ring is full, and driver will
-print the following error message:
-
-    "xhci_hcd 0000:00:14.0: failed to queue trbs"
-
-This is a normal case for 'in' transfers where TRBs are always enqueued
-in advance, ready to take on incoming data. If no data arrives, and
-device is disconnected, then ring dequeue will remain at beginning of
-the ring while enqueue points to first free TRB after last cancelled
-No-op TRB.
-s
-Solve this by reinitializing the rings when the debug cable disconnects
-and DbC is leaving the configured state.
-Clear the whole ring buffer and set enqueue and dequeue to the beginning
-of ring, and set cycle bit to its initial state.
-
-Cc: stable@vger.kernel.org
-Fixes: dfba2174dc42 ("usb: xhci: Add DbC support in xHCI driver")
-Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
-Link: https://lore.kernel.org/r/20250902105306.877476-3-mathias.nyman@linux.intel.com
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- drivers/usb/host/xhci-dbgcap.c |   23 +++++++++++++++++++++--
- 1 file changed, 21 insertions(+), 2 deletions(-)
-
---- a/drivers/usb/host/xhci-dbgcap.c
-+++ b/drivers/usb/host/xhci-dbgcap.c
-@@ -421,6 +421,25 @@ dbc_alloc_ctx(struct device *dev, gfp_t
-       return ctx;
- }
-+static int xhci_dbc_reinit_ep_rings(struct xhci_dbc *dbc)
-+{
-+      struct xhci_ring *in_ring = dbc->eps[BULK_IN].ring;
-+      struct xhci_ring *out_ring = dbc->eps[BULK_OUT].ring;
-+
-+      if (!in_ring || !out_ring || !dbc->ctx) {
-+              dev_warn(dbc->dev, "Can't re-init unallocated endpoints\n");
-+              return -ENODEV;
-+      }
-+
-+      xhci_dbc_ring_init(in_ring);
-+      xhci_dbc_ring_init(out_ring);
-+
-+      /* set ep context enqueue, dequeue, and cycle to initial values */
-+      xhci_dbc_init_ep_contexts(dbc);
-+
-+      return 0;
-+}
-+
- static struct xhci_ring *
- xhci_dbc_ring_alloc(struct device *dev, enum xhci_ring_type type, gfp_t flags)
- {
-@@ -850,7 +869,7 @@ static enum evtreturn xhci_dbc_do_handle
-                       dev_info(dbc->dev, "DbC cable unplugged\n");
-                       dbc->state = DS_ENABLED;
-                       xhci_dbc_flush_requests(dbc);
--
-+                      xhci_dbc_reinit_ep_rings(dbc);
-                       return EVT_DISC;
-               }
-@@ -860,7 +879,7 @@ static enum evtreturn xhci_dbc_do_handle
-                       writel(portsc, &dbc->regs->portsc);
-                       dbc->state = DS_ENABLED;
-                       xhci_dbc_flush_requests(dbc);
--
-+                      xhci_dbc_reinit_ep_rings(dbc);
-                       return EVT_DISC;
-               }