[PATCH 3/4] thunderbolt: improve usb3 adapter link up timeout value
Chunfeng Yun (云春峰)
Chunfeng.Yun at mediatek.com
Tue Nov 3 00:13:29 PST 2026
On Fri, 2026-10-30 at 09:50 +0100, Mika Westerberg wrote:
> On Fri, Oct 30, 2026 at 04:25:38PM +0800, Chunfeng Yun wrote:
> > when plug into a usb3 device into usb4 hub's DFP to trigger usb4
>
> USB 3 device into USB4 hub's downstream facing port to ...
Ok
>
> > driver wakeup, encounter usb3 link up timeout issue, then cause
> > usb3 hub disconnect:
> >
> > usb4_hi NVDA8100:00: 0:1: failed to reach state TB_PORT_UP.
> > Ignoring port...
> > usb4_hi NVDA8100:00: 0:1: lost during suspend, disconnecting
> > usb4_hi NVDA8100:00: 0:4 <-> 1:20 (USB3): deactivating
> > usb4_hi NVDA8100:00: deactivating USB3 Down path from 0:4 to 1:20
> > usb4_hi NVDA8100:00: deactivating USB3 Up path from 1:20 to 0:4
> > ...
> > thunderbolt 0-1: device disconnected
> > usb 2-1: USB disconnect, device number 10
> >
> > Completes link training at ~1.48s and transitions to TB_PORT_UP
> > after
> > change the timeout to 2.5s:
> >
> > In the USB4 spec, Phase 5 (Link Equalization) alone is allowed up
> > to
> > 1000 ms. When add tPhase3 (100 ms), tPhase4 (100 ms), and retimer
> > transaction delays (tCmdResponse = 50 ms), the physical link is
> > allowed by spec to take 1200 ms to 1500 ms+ to complete
> > initialization.
> >
> > here are two retimers in the link, if more retimers add it, need
> > more
> > time
> >
> > Signed-off-by: Chunfeng Yun <chunfeng.yun at mediatek.com>
> > ---
> > drivers/thunderbolt/switch.c | 3 ++-
> > 1 file changed, 2 insertions(+), 1 deletion(-)
> >
> > diff --git a/drivers/thunderbolt/switch.c
> > b/drivers/thunderbolt/switch.c
> > index d22d8db8f890..e7ee9639c54c 100644
> > --- a/drivers/thunderbolt/switch.c
> > +++ b/drivers/thunderbolt/switch.c
> > @@ -500,8 +500,9 @@ int tb_port_state(struct tb_port *port)
> > */
> > int tb_wait_for_port(struct tb_port *port, bool wait_if_unplugged)
> > {
> > - int retries = 10;
> > + int retries = 25;
> > int state;
> > +
>
> This is unrelated change.
will remove it.
Thanks
>
> > if (!port->cap_phy) {
> > tb_port_WARN(port, "does not have PHY\n");
> > return -EINVAL;
> > --
> > 2.43.0
More information about the linux-arm-kernel
mailing list