All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] usb: xhci: add xhci-no-soft-retry-quirk
@ 2026-08-28 12:37 ` Matt Eaton
  0 siblings, 0 replies; 11+ messages in thread
From: Matt Eaton via B4 Relay @ 2026-08-28 12:37 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Mathias Nyman
  Cc: linux-usb, devicetree, linux-kernel, Matt Eaton

This series adds an opt-in device property so platform xHCI hosts can
request the XHCI_NO_SOFT_RETRY quirk, currently only reachable from
xhci-pci matched against two AMD Promontory PCI ids.

Motivating case: the Synopsys DWC3 xHCI instances on Qualcomm IPQ4019
mishandle xHCI 1.0 Soft Retry. A Stop Endpoint command landing on a
just-soft-retry-reset endpoint wedges the command ring; the
stop-endpoint watchdog then kills the host five seconds later. Setting
the property falls back to the pre-Soft-Retry recovery path (full
endpoint reset), which the vendor's 4.4 kernel uses unconditionally
and which is well tolerated on this hardware.

Patch 1 documents the property. Patch 2 wires it into xhci-plat.c.

The devicetree change enabling this on IPQ4019 is being sent
separately to linux-arm-msm, since this series only adds the
mechanism.

Signed-off-by: Matt Eaton <linux@divinehawk.com>
---
Matt Eaton (2):
      dt-bindings: usb: xhci: add xhci-no-soft-retry-quirk
      usb: xhci-plat: add xhci-no-soft-retry-quirk device property

 Documentation/devicetree/bindings/usb/usb-xhci.yaml | 4 ++++
 drivers/usb/host/xhci-plat.c                        | 3 +++
 2 files changed, 7 insertions(+)
---
base-commit: 45c13f3f9e3bb15fd89ff2864c6f627a3b4b4229
change-id: 20260828-xhci-no-soft-retry-4af6c93dc7d2

Best regards,
--  
Matt Eaton <linux@divinehawk.com>



^ permalink raw reply	[flat|nested] 11+ messages in thread

* [PATCH 0/2] usb: xhci: add xhci-no-soft-retry-quirk
@ 2026-08-28 12:37 ` Matt Eaton
  0 siblings, 0 replies; 11+ messages in thread
From: Matt Eaton @ 2026-08-28 12:37 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Mathias Nyman
  Cc: linux-usb, devicetree, linux-kernel, Matt Eaton

This series adds an opt-in device property so platform xHCI hosts can
request the XHCI_NO_SOFT_RETRY quirk, currently only reachable from
xhci-pci matched against two AMD Promontory PCI ids.

Motivating case: the Synopsys DWC3 xHCI instances on Qualcomm IPQ4019
mishandle xHCI 1.0 Soft Retry. A Stop Endpoint command landing on a
just-soft-retry-reset endpoint wedges the command ring; the
stop-endpoint watchdog then kills the host five seconds later. Setting
the property falls back to the pre-Soft-Retry recovery path (full
endpoint reset), which the vendor's 4.4 kernel uses unconditionally
and which is well tolerated on this hardware.

Patch 1 documents the property. Patch 2 wires it into xhci-plat.c.

The devicetree change enabling this on IPQ4019 is being sent
separately to linux-arm-msm, since this series only adds the
mechanism.

Signed-off-by: Matt Eaton <linux@divinehawk.com>
---
Matt Eaton (2):
      dt-bindings: usb: xhci: add xhci-no-soft-retry-quirk
      usb: xhci-plat: add xhci-no-soft-retry-quirk device property

 Documentation/devicetree/bindings/usb/usb-xhci.yaml | 4 ++++
 drivers/usb/host/xhci-plat.c                        | 3 +++
 2 files changed, 7 insertions(+)
---
base-commit: 45c13f3f9e3bb15fd89ff2864c6f627a3b4b4229
change-id: 20260828-xhci-no-soft-retry-4af6c93dc7d2

Best regards,
--  
Matt Eaton <linux@divinehawk.com>


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [PATCH 1/2] dt-bindings: usb: xhci: add xhci-no-soft-retry-quirk
  2026-08-28 12:37 ` Matt Eaton
@ 2026-08-28 12:37   ` Matt Eaton
  -1 siblings, 0 replies; 11+ messages in thread
From: Matt Eaton via B4 Relay @ 2026-08-28 12:37 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Mathias Nyman
  Cc: linux-usb, devicetree, linux-kernel, Matt Eaton

From: Matt Eaton <linux@divinehawk.com>

Document the xhci-no-soft-retry-quirk property, added in the
following patch.

snps,dwc3-common.yaml refs usb-xhci.yaml for every dr_mode other than
peripheral, so a host-mode dwc3 node inherits it and dt_binding_check
accepts it there.

Signed-off-by: Matt Eaton <linux@divinehawk.com>
---
 Documentation/devicetree/bindings/usb/usb-xhci.yaml | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/Documentation/devicetree/bindings/usb/usb-xhci.yaml b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
index 4238ae896ef6..5d67a41658f7 100644
--- a/Documentation/devicetree/bindings/usb/usb-xhci.yaml
+++ b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
@@ -25,6 +25,10 @@ properties:
     description: Set if the controller has broken port disable mechanism
     type: boolean
 
+  xhci-no-soft-retry-quirk:
+    description: Set if the controller cannot perform xHCI Soft Retry correctly
+    type: boolean
+
   imod-interval-ns:
     description: Interrupt moderation interval
     default: 5000

-- 
2.43.0



^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 1/2] dt-bindings: usb: xhci: add xhci-no-soft-retry-quirk
@ 2026-08-28 12:37   ` Matt Eaton
  0 siblings, 0 replies; 11+ messages in thread
From: Matt Eaton @ 2026-08-28 12:37 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Mathias Nyman
  Cc: linux-usb, devicetree, linux-kernel, Matt Eaton

Document the xhci-no-soft-retry-quirk property, added in the
following patch.

snps,dwc3-common.yaml refs usb-xhci.yaml for every dr_mode other than
peripheral, so a host-mode dwc3 node inherits it and dt_binding_check
accepts it there.

Signed-off-by: Matt Eaton <linux@divinehawk.com>
---
 Documentation/devicetree/bindings/usb/usb-xhci.yaml | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/Documentation/devicetree/bindings/usb/usb-xhci.yaml b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
index 4238ae896ef6..5d67a41658f7 100644
--- a/Documentation/devicetree/bindings/usb/usb-xhci.yaml
+++ b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
@@ -25,6 +25,10 @@ properties:
     description: Set if the controller has broken port disable mechanism
     type: boolean
 
+  xhci-no-soft-retry-quirk:
+    description: Set if the controller cannot perform xHCI Soft Retry correctly
+    type: boolean
+
   imod-interval-ns:
     description: Interrupt moderation interval
     default: 5000

-- 
2.43.0


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 2/2] usb: xhci-plat: add xhci-no-soft-retry-quirk device property
  2026-08-28 12:37 ` Matt Eaton
@ 2026-08-28 12:37   ` Matt Eaton
  -1 siblings, 0 replies; 11+ messages in thread
From: Matt Eaton via B4 Relay @ 2026-08-28 12:37 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Mathias Nyman
  Cc: linux-usb, devicetree, linux-kernel, Matt Eaton

From: Matt Eaton <linux@divinehawk.com>

XHCI_NO_SOFT_RETRY exists for hosts that can't perform xHCI 1.0 Soft Retry
correctly, but it's only reachable from xhci-pci, matched against two AMD
Promontory PCI ids. Platform hosts have no way to ask for it.

Add it as a device property, the same way as quirk-broken-port-ped and its
neighbors. It's opt-in, so no existing platform is affected.

Needed for the Synopsys DWC3 on a Qualcomm IPQ4019, whose command ring
wedges when a Stop Endpoint command lands on a just-soft-retry-reset
endpoint -- exactly what unplugging a device mid-transfer triggers:

xhci-hcd xhci-hcd.1.auto: xHCI host not responding to stop endpoint command
xhci-hcd xhci-hcd.1.auto: xHCI host controller not responding, assume dead
xhci-hcd xhci-hcd.1.auto: HC died; cleaning up

Signed-off-by: Matt Eaton <linux@divinehawk.com>
---
 drivers/usb/host/xhci-plat.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/usb/host/xhci-plat.c b/drivers/usb/host/xhci-plat.c
index 6fd595f81a30..22057493f935 100644
--- a/drivers/usb/host/xhci-plat.c
+++ b/drivers/usb/host/xhci-plat.c
@@ -265,6 +265,9 @@ int xhci_plat_probe(struct platform_device *pdev, struct device *sysdev, const s
 		if (device_property_read_bool(tmpdev, "quirk-broken-port-ped"))
 			xhci->quirks |= XHCI_BROKEN_PORT_PED;
 
+		if (device_property_read_bool(tmpdev, "xhci-no-soft-retry-quirk"))
+			xhci->quirks |= XHCI_NO_SOFT_RETRY;
+
 		if (device_property_read_bool(tmpdev, "xhci-sg-trb-cache-size-quirk"))
 			xhci->quirks |= XHCI_SG_TRB_CACHE_SIZE_QUIRK;
 

-- 
2.43.0



^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 2/2] usb: xhci-plat: add xhci-no-soft-retry-quirk device property
@ 2026-08-28 12:37   ` Matt Eaton
  0 siblings, 0 replies; 11+ messages in thread
From: Matt Eaton @ 2026-08-28 12:37 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Mathias Nyman
  Cc: linux-usb, devicetree, linux-kernel, Matt Eaton

XHCI_NO_SOFT_RETRY exists for hosts that can't perform xHCI 1.0 Soft Retry
correctly, but it's only reachable from xhci-pci, matched against two AMD
Promontory PCI ids. Platform hosts have no way to ask for it.

Add it as a device property, the same way as quirk-broken-port-ped and its
neighbors. It's opt-in, so no existing platform is affected.

Needed for the Synopsys DWC3 on a Qualcomm IPQ4019, whose command ring
wedges when a Stop Endpoint command lands on a just-soft-retry-reset
endpoint -- exactly what unplugging a device mid-transfer triggers:

xhci-hcd xhci-hcd.1.auto: xHCI host not responding to stop endpoint command
xhci-hcd xhci-hcd.1.auto: xHCI host controller not responding, assume dead
xhci-hcd xhci-hcd.1.auto: HC died; cleaning up

Signed-off-by: Matt Eaton <linux@divinehawk.com>
---
 drivers/usb/host/xhci-plat.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/usb/host/xhci-plat.c b/drivers/usb/host/xhci-plat.c
index 6fd595f81a30..22057493f935 100644
--- a/drivers/usb/host/xhci-plat.c
+++ b/drivers/usb/host/xhci-plat.c
@@ -265,6 +265,9 @@ int xhci_plat_probe(struct platform_device *pdev, struct device *sysdev, const s
 		if (device_property_read_bool(tmpdev, "quirk-broken-port-ped"))
 			xhci->quirks |= XHCI_BROKEN_PORT_PED;
 
+		if (device_property_read_bool(tmpdev, "xhci-no-soft-retry-quirk"))
+			xhci->quirks |= XHCI_NO_SOFT_RETRY;
+
 		if (device_property_read_bool(tmpdev, "xhci-sg-trb-cache-size-quirk"))
 			xhci->quirks |= XHCI_SG_TRB_CACHE_SIZE_QUIRK;
 

-- 
2.43.0


^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: [PATCH 1/2] dt-bindings: usb: xhci: add xhci-no-soft-retry-quirk
  2026-08-28 12:37   ` Matt Eaton
  (?)
@ 2026-08-28 12:39   ` Krzysztof Kozlowski
  2026-08-28 13:18     ` Matt Eaton
  -1 siblings, 1 reply; 11+ messages in thread
From: Krzysztof Kozlowski @ 2026-08-28 12:39 UTC (permalink / raw)
  To: linux, Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Mathias Nyman
  Cc: linux-usb, devicetree, linux-kernel

On 28/08/2026 14:37, Matt Eaton via B4 Relay wrote:
> From: Matt Eaton <linux@divinehawk.com>
> 
> Document the xhci-no-soft-retry-quirk property, added in the
> following patch.
> 
> snps,dwc3-common.yaml refs usb-xhci.yaml for every dr_mode other than
> peripheral, so a host-mode dwc3 node inherits it and dt_binding_check
> accepts it there.

I do not understand how this sentence is relevant. Please describe the
hardware needing this.


> 
> Signed-off-by: Matt Eaton <linux@divinehawk.com>
> ---
>  Documentation/devicetree/bindings/usb/usb-xhci.yaml | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/usb/usb-xhci.yaml b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
> index 4238ae896ef6..5d67a41658f7 100644
> --- a/Documentation/devicetree/bindings/usb/usb-xhci.yaml
> +++ b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
> @@ -25,6 +25,10 @@ properties:
>      description: Set if the controller has broken port disable mechanism
>      type: boolean
>  
> +  xhci-no-soft-retry-quirk:
> +    description: Set if the controller cannot perform xHCI Soft Retry correctly

Why isn't this implied by compatible? Looks like controller's property.


Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 1/2] dt-bindings: usb: xhci: add xhci-no-soft-retry-quirk
  2026-08-28 12:39   ` Krzysztof Kozlowski
@ 2026-08-28 13:18     ` Matt Eaton
  2026-08-28 13:53       ` Krzysztof Kozlowski
  0 siblings, 1 reply; 11+ messages in thread
From: Matt Eaton @ 2026-08-28 13:18 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Mathias Nyman, linux-usb, devicetree, linux-kernel

On Fri, Aug 28, 2026 at 2:39 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
>
> On 28/08/2026 14:37, Matt Eaton via B4 Relay wrote:
> > From: Matt Eaton <linux@divinehawk.com>
> >
> > Document the xhci-no-soft-retry-quirk property, added in the
> > following patch.
> >
> > snps,dwc3-common.yaml refs usb-xhci.yaml for every dr_mode other than
> > peripheral, so a host-mode dwc3 node inherits it and dt_binding_check
> > accepts it there.
>
> I do not understand how this sentence is relevant. Please describe the
> hardware needing this.

I came across this while porting the UniFi Travel Router (IPQ4018),
the stock Qualcomm kernel is 4.4.60 which predates the soft retry
code. The command ring hangs if you disconnect the device while it's
transmitting. Reproducible consistently when using USB to tether to a
phone.

> >
> > Signed-off-by: Matt Eaton <linux@divinehawk.com>
> > ---
> >  Documentation/devicetree/bindings/usb/usb-xhci.yaml | 4 ++++
> >  1 file changed, 4 insertions(+)
> >
> > diff --git a/Documentation/devicetree/bindings/usb/usb-xhci.yaml b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
> > index 4238ae896ef6..5d67a41658f7 100644
> > --- a/Documentation/devicetree/bindings/usb/usb-xhci.yaml
> > +++ b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
> > @@ -25,6 +25,10 @@ properties:
> >      description: Set if the controller has broken port disable mechanism
> >      type: boolean
> >
> > +  xhci-no-soft-retry-quirk:
> > +    description: Set if the controller cannot perform xHCI Soft Retry correctly
>
> Why isn't this implied by compatible? Looks like controller's property.

The xhci device is created by dwc3 core as a child device, and so
xhci_plat_probe() is used. I think a DT property is the right
approach, similar to quirk-broken-port-ped, but to set
XHCI_NO_SOFT_RETRY.

>
> Best regards,
> Krzysztof

Cheers,
Matt Eaton

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 1/2] dt-bindings: usb: xhci: add xhci-no-soft-retry-quirk
  2026-08-28 13:18     ` Matt Eaton
@ 2026-08-28 13:53       ` Krzysztof Kozlowski
  2026-08-28 16:07         ` Matt Eaton
  0 siblings, 1 reply; 11+ messages in thread
From: Krzysztof Kozlowski @ 2026-08-28 13:53 UTC (permalink / raw)
  To: Matt Eaton
  Cc: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Mathias Nyman, linux-usb, devicetree, linux-kernel

On 28/08/2026 15:18, Matt Eaton wrote:
> On Fri, Aug 28, 2026 at 2:39 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
>>
>> On 28/08/2026 14:37, Matt Eaton via B4 Relay wrote:
>>> From: Matt Eaton <linux@divinehawk.com>
>>>
>>> Document the xhci-no-soft-retry-quirk property, added in the
>>> following patch.
>>>
>>> snps,dwc3-common.yaml refs usb-xhci.yaml for every dr_mode other than
>>> peripheral, so a host-mode dwc3 node inherits it and dt_binding_check
>>> accepts it there.
>>
>> I do not understand how this sentence is relevant. Please describe the
>> hardware needing this.
> 
> I came across this while porting the UniFi Travel Router (IPQ4018),
> the stock Qualcomm kernel is 4.4.60 which predates the soft retry
> code. The command ring hangs if you disconnect the device while it's
> transmitting. Reproducible consistently when using USB to tether to a
> phone.
> 
>>>
>>> Signed-off-by: Matt Eaton <linux@divinehawk.com>
>>> ---
>>>  Documentation/devicetree/bindings/usb/usb-xhci.yaml | 4 ++++
>>>  1 file changed, 4 insertions(+)
>>>
>>> diff --git a/Documentation/devicetree/bindings/usb/usb-xhci.yaml b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
>>> index 4238ae896ef6..5d67a41658f7 100644
>>> --- a/Documentation/devicetree/bindings/usb/usb-xhci.yaml
>>> +++ b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
>>> @@ -25,6 +25,10 @@ properties:
>>>      description: Set if the controller has broken port disable mechanism
>>>      type: boolean
>>>
>>> +  xhci-no-soft-retry-quirk:
>>> +    description: Set if the controller cannot perform xHCI Soft Retry correctly
>>
>> Why isn't this implied by compatible? Looks like controller's property.
> 
> The xhci device is created by dwc3 core as a child device, and so
> xhci_plat_probe() is used. I think a DT property is the right
> approach, similar to quirk-broken-port-ped, but to set
> XHCI_NO_SOFT_RETRY.

Linux driver behavior should not matter here. DT property for telling
Linux what to do is not the right approach. As I said, it's implied by
compatible unless you bring hardware reasons why it is not. Driver
reasons don't matter.

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 1/2] dt-bindings: usb: xhci: add xhci-no-soft-retry-quirk
  2026-08-28 13:53       ` Krzysztof Kozlowski
@ 2026-08-28 16:07         ` Matt Eaton
  2026-08-28 17:50           ` Krishna Kurapati
  0 siblings, 1 reply; 11+ messages in thread
From: Matt Eaton @ 2026-08-28 16:07 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Mathias Nyman, linux-usb, devicetree, linux-kernel

On Fri, Aug 28, 2026 at 3:53 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
>
> On 28/08/2026 15:18, Matt Eaton wrote:
> > On Fri, Aug 28, 2026 at 2:39 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
> >>
> >> On 28/08/2026 14:37, Matt Eaton via B4 Relay wrote:
> >>> From: Matt Eaton <linux@divinehawk.com>
> >>>
> >>> Document the xhci-no-soft-retry-quirk property, added in the
> >>> following patch.
> >>>
> >>> snps,dwc3-common.yaml refs usb-xhci.yaml for every dr_mode other than
> >>> peripheral, so a host-mode dwc3 node inherits it and dt_binding_check
> >>> accepts it there.
> >>
> >> I do not understand how this sentence is relevant. Please describe the
> >> hardware needing this.
> >
> > I came across this while porting the UniFi Travel Router (IPQ4018),
> > the stock Qualcomm kernel is 4.4.60 which predates the soft retry
> > code. The command ring hangs if you disconnect the device while it's
> > transmitting. Reproducible consistently when using USB to tether to a
> > phone.
> >
> >>>
> >>> Signed-off-by: Matt Eaton <linux@divinehawk.com>
> >>> ---
> >>>  Documentation/devicetree/bindings/usb/usb-xhci.yaml | 4 ++++
> >>>  1 file changed, 4 insertions(+)
> >>>
> >>> diff --git a/Documentation/devicetree/bindings/usb/usb-xhci.yaml b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
> >>> index 4238ae896ef6..5d67a41658f7 100644
> >>> --- a/Documentation/devicetree/bindings/usb/usb-xhci.yaml
> >>> +++ b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
> >>> @@ -25,6 +25,10 @@ properties:
> >>>      description: Set if the controller has broken port disable mechanism
> >>>      type: boolean
> >>>
> >>> +  xhci-no-soft-retry-quirk:
> >>> +    description: Set if the controller cannot perform xHCI Soft Retry correctly
> >>
> >> Why isn't this implied by compatible? Looks like controller's property.
> >
> > The xhci device is created by dwc3 core as a child device, and so
> > xhci_plat_probe() is used. I think a DT property is the right
> > approach, similar to quirk-broken-port-ped, but to set
> > XHCI_NO_SOFT_RETRY.
>
> Linux driver behavior should not matter here. DT property for telling
> Linux what to do is not the right approach. As I said, it's implied by
> compatible unless you bring hardware reasons why it is not. Driver
> reasons don't matter.

Will rework without DT property. Appreciate the feedback!

Best,
Matt

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 1/2] dt-bindings: usb: xhci: add xhci-no-soft-retry-quirk
  2026-08-28 16:07         ` Matt Eaton
@ 2026-08-28 17:50           ` Krishna Kurapati
  0 siblings, 0 replies; 11+ messages in thread
From: Krishna Kurapati @ 2026-08-28 17:50 UTC (permalink / raw)
  To: Matt Eaton, Krzysztof Kozlowski
  Cc: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Mathias Nyman, linux-usb, devicetree, linux-kernel



On 8/28/2026 9:37 PM, Matt Eaton wrote:
> On Fri, Aug 28, 2026 at 3:53 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
>>
>> On 28/08/2026 15:18, Matt Eaton wrote:
>>> On Fri, Aug 28, 2026 at 2:39 PM Krzysztof Kozlowski <krzk@kernel.org> wrote:
>>>>
>>>> On 28/08/2026 14:37, Matt Eaton via B4 Relay wrote:
>>>>> From: Matt Eaton <linux@divinehawk.com>
>>>>>
>>>>> Document the xhci-no-soft-retry-quirk property, added in the
>>>>> following patch.
>>>>>
>>>>> snps,dwc3-common.yaml refs usb-xhci.yaml for every dr_mode other than
>>>>> peripheral, so a host-mode dwc3 node inherits it and dt_binding_check
>>>>> accepts it there.
>>>>
>>>> I do not understand how this sentence is relevant. Please describe the
>>>> hardware needing this.
>>>
>>> I came across this while porting the UniFi Travel Router (IPQ4018),
>>> the stock Qualcomm kernel is 4.4.60 which predates the soft retry
>>> code. The command ring hangs if you disconnect the device while it's
>>> transmitting. Reproducible consistently when using USB to tether to a
>>> phone.
>>>
>>>>>
>>>>> Signed-off-by: Matt Eaton <linux@divinehawk.com>
>>>>> ---
>>>>>   Documentation/devicetree/bindings/usb/usb-xhci.yaml | 4 ++++
>>>>>   1 file changed, 4 insertions(+)
>>>>>
>>>>> diff --git a/Documentation/devicetree/bindings/usb/usb-xhci.yaml b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
>>>>> index 4238ae896ef6..5d67a41658f7 100644
>>>>> --- a/Documentation/devicetree/bindings/usb/usb-xhci.yaml
>>>>> +++ b/Documentation/devicetree/bindings/usb/usb-xhci.yaml
>>>>> @@ -25,6 +25,10 @@ properties:
>>>>>       description: Set if the controller has broken port disable mechanism
>>>>>       type: boolean
>>>>>
>>>>> +  xhci-no-soft-retry-quirk:
>>>>> +    description: Set if the controller cannot perform xHCI Soft Retry correctly
>>>>
>>>> Why isn't this implied by compatible? Looks like controller's property.
>>>
>>> The xhci device is created by dwc3 core as a child device, and so
>>> xhci_plat_probe() is used. I think a DT property is the right
>>> approach, similar to quirk-broken-port-ped, but to set
>>> XHCI_NO_SOFT_RETRY.
>>
>> Linux driver behavior should not matter here. DT property for telling
>> Linux what to do is not the right approach. As I said, it's implied by
>> compatible unless you bring hardware reasons why it is not. Driver
>> reasons don't matter.
> 
> Will rework without DT property. Appreciate the feedback!
> 
If you have any upstream QC target that needs this, you can use the 
following patch as reference:

https://lore.kernel.org/all/20260723-dwc3-skip-init-quirk-v1-1-97682bb44ebd@oss.qualcomm.com/

Regards,
Krishna,

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2026-08-28 17:50 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-28 12:37 [PATCH 0/2] usb: xhci: add xhci-no-soft-retry-quirk Matt Eaton via B4 Relay
2026-08-28 12:37 ` Matt Eaton
2026-08-28 12:37 ` [PATCH 1/2] dt-bindings: " Matt Eaton via B4 Relay
2026-08-28 12:37   ` Matt Eaton
2026-08-28 12:39   ` Krzysztof Kozlowski
2026-08-28 13:18     ` Matt Eaton
2026-08-28 13:53       ` Krzysztof Kozlowski
2026-08-28 16:07         ` Matt Eaton
2026-08-28 17:50           ` Krishna Kurapati
2026-08-28 12:37 ` [PATCH 2/2] usb: xhci-plat: add xhci-no-soft-retry-quirk device property Matt Eaton via B4 Relay
2026-08-28 12:37   ` Matt Eaton

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.