U-Boot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Revert "drivers: usb: dwc3: Add delay after core soft reset"
@ 2026-07-24  9:28 Balaji Selvanathan via U-Boot
  2026-07-24 12:41 ` Marek Vasut via U-Boot
  2026-07-24 13:42 ` Mattijs Korpershoek
  0 siblings, 2 replies; 4+ messages in thread
From: Balaji Selvanathan via U-Boot @ 2026-07-24  9:28 UTC (permalink / raw)
  To: u-boot
  Cc: Marek Vasut, Tom Rini, Mattijs Korpershoek, Chris Morgan,
	Balaji Selvanathan

This reverts commit 6de333b5caf035c38d7af9fa7596aeffcc49db42.

The delay is unnecessary. Upstream Linux does not add this delay after
the core soft reset and the USB works fine without it.

Tested in QCS6490 RB3Gen2 Qualcomm board.

Signed-off-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
---
- This is part of ongoing initiative to reduce boot time across all
  Qualcomm boards. So we can remove this unnecessary delay.
- Actually, this delay was removed in the Kodiak v4 series:
  https://lore.kernel.org/u-boot/20260418-kodiak_ss-v4-0-d381670c9d78@oss.qualcomm.com/
  but v3 series got picked up: https://lore.kernel.org/u-boot/177745255938.126665.16625119085748603933.b4-ty@b4/
---
 drivers/usb/dwc3/core.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
index be198041f08..ae22e1c792d 100644
--- a/drivers/usb/dwc3/core.c
+++ b/drivers/usb/dwc3/core.c
@@ -106,8 +106,6 @@ done:
 	if (DWC3_VER_IS_WITHIN(DWC31, ANY, 180A))
 		mdelay(50);
 
-	mdelay(100);
-
 	return 0;
 }
 

---
base-commit: d7ef23c07b8e34f65b3e15e3b4e7f58d074923c8
change-id: 20260724-kodiak_delay-a5f1e8b675cd

Best regards,
-- 
Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>


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

* Re: [PATCH] Revert "drivers: usb: dwc3: Add delay after core soft reset"
  2026-07-24  9:28 [PATCH] Revert "drivers: usb: dwc3: Add delay after core soft reset" Balaji Selvanathan via U-Boot
@ 2026-07-24 12:41 ` Marek Vasut via U-Boot
  2026-07-26 10:06   ` Balaji Selvanathan via U-Boot
  2026-07-24 13:42 ` Mattijs Korpershoek
  1 sibling, 1 reply; 4+ messages in thread
From: Marek Vasut via U-Boot @ 2026-07-24 12:41 UTC (permalink / raw)
  To: Balaji Selvanathan, u-boot
  Cc: Marek Vasut, Tom Rini, Mattijs Korpershoek, Chris Morgan

On 7/24/26 11:28 AM, Balaji Selvanathan wrote:
> This reverts commit 6de333b5caf035c38d7af9fa7596aeffcc49db42.
> 
> The delay is unnecessary. Upstream Linux does not add this delay after
> the core soft reset and the USB works fine without it.
> 
> Tested in QCS6490 RB3Gen2 Qualcomm board.
The reverted commit states this:

"
     Without this delay, USB initialization can fail on some Qualcomm
     platforms, particularly when using super-speed capable PHYs like
     the QMP USB3-DP Combo PHY on SC7280/QCM6490.

     Taken from Linux commit f88359e1588b ("usb: dwc3: core: Do core 
softreset when switch mode")
"

Can you test this on one of those two listed devices ?

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

* Re: [PATCH] Revert "drivers: usb: dwc3: Add delay after core soft reset"
  2026-07-24  9:28 [PATCH] Revert "drivers: usb: dwc3: Add delay after core soft reset" Balaji Selvanathan via U-Boot
  2026-07-24 12:41 ` Marek Vasut via U-Boot
@ 2026-07-24 13:42 ` Mattijs Korpershoek
  1 sibling, 0 replies; 4+ messages in thread
From: Mattijs Korpershoek @ 2026-07-24 13:42 UTC (permalink / raw)
  To: Balaji Selvanathan, u-boot
  Cc: Marek Vasut, Tom Rini, Mattijs Korpershoek, Chris Morgan,
	Balaji Selvanathan

Hi Balaji,

Thank you for the patch.

On Fri, Jul 24, 2026 at 14:58, Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com> wrote:

> This reverts commit 6de333b5caf035c38d7af9fa7596aeffcc49db42.
>
> The delay is unnecessary. Upstream Linux does not add this delay after
> the core soft reset and the USB works fine without it.
>
> Tested in QCS6490 RB3Gen2 Qualcomm board.
>
> Signed-off-by: Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>
> ---
> - This is part of ongoing initiative to reduce boot time across all
>   Qualcomm boards. So we can remove this unnecessary delay.
> - Actually, this delay was removed in the Kodiak v4 series:
>   https://lore.kernel.org/u-boot/20260418-kodiak_ss-v4-0-d381670c9d78@oss.qualcomm.com/
>   but v3 series got picked up: https://lore.kernel.org/u-boot/177745255938.126665.16625119085748603933.b4-ty@b4/
> ---
>  drivers/usb/dwc3/core.c | 2 --
>  1 file changed, 2 deletions(-)
>
> diff --git a/drivers/usb/dwc3/core.c b/drivers/usb/dwc3/core.c
> index be198041f08..ae22e1c792d 100644
> --- a/drivers/usb/dwc3/core.c
> +++ b/drivers/usb/dwc3/core.c
> @@ -106,8 +106,6 @@ done:
>  	if (DWC3_VER_IS_WITHIN(DWC31, ANY, 180A))
>  		mdelay(50);
>  
> -	mdelay(100);
> -

The dwc3 driver is not only used by qualcomm, but many other SoCs.

That delay indeed does not exist as is in the Linux driver since the
following commit f59dcab17629 ("usb: dwc3: core: improve reset sequence")

However, that commit is more conservative by adding retries and such.

I'd prefer to stick with Linux's approach here.

Also note, there is an ongoing effort of updating the dwc3 driver by
Linaro here:

https://lore.kernel.org/all/20260716134305.614278-1-anders.roxell@linaro.org/

Could you maybe give that a try? It should have the
"usb: dwc3: core: improve reset sequence" patch in there.

>  	return 0;
>  }
>  
>
> ---
> base-commit: d7ef23c07b8e34f65b3e15e3b4e7f58d074923c8
> change-id: 20260724-kodiak_delay-a5f1e8b675cd
>
> Best regards,
> -- 
> Balaji Selvanathan <balaji.selvanathan@oss.qualcomm.com>

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

* Re: [PATCH] Revert "drivers: usb: dwc3: Add delay after core soft reset"
  2026-07-24 12:41 ` Marek Vasut via U-Boot
@ 2026-07-26 10:06   ` Balaji Selvanathan via U-Boot
  0 siblings, 0 replies; 4+ messages in thread
From: Balaji Selvanathan via U-Boot @ 2026-07-26 10:06 UTC (permalink / raw)
  To: Marek Vasut, u-boot
  Cc: Marek Vasut, Tom Rini, Mattijs Korpershoek, Chris Morgan

Hi Marek,

On 7/24/2026 6:11 PM, Marek Vasut wrote:
> On 7/24/26 11:28 AM, Balaji Selvanathan wrote:
>> This reverts commit 6de333b5caf035c38d7af9fa7596aeffcc49db42.
>>
>> The delay is unnecessary. Upstream Linux does not add this delay after
>> the core soft reset and the USB works fine without it.
>>
>> Tested in QCS6490 RB3Gen2 Qualcomm board.
> The reverted commit states this:
>
> "
>     Without this delay, USB initialization can fail on some Qualcomm
>     platforms, particularly when using super-speed capable PHYs like
>     the QMP USB3-DP Combo PHY on SC7280/QCM6490.
>
>     Taken from Linux commit f88359e1588b ("usb: dwc3: core: Do core 
> softreset when switch mode")
> "
>
> Can you test this on one of those two listed devices ?

It's tested in QCM6490 (another name QCS6490). USB init works fine 
without this delay.

Regards,

Balaji


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

end of thread, other threads:[~2026-07-26 10:06 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-24  9:28 [PATCH] Revert "drivers: usb: dwc3: Add delay after core soft reset" Balaji Selvanathan via U-Boot
2026-07-24 12:41 ` Marek Vasut via U-Boot
2026-07-26 10:06   ` Balaji Selvanathan via U-Boot
2026-07-24 13:42 ` Mattijs Korpershoek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox