All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mika Westerberg <mika.westerberg@linux.intel.com>
To: Phani Kumar <phanigudipally@gmail.com>
Cc: Mathias Nyman <mathias.nyman@linux.intel.com>, linux-usb@vger.kernel.org
Subject: Re: [WARNING: UNSCANNABLE EXTRACTION FAILED]Re: xhci_hcd 0000:00:0d.0 (Panther Lake, 8086:e431): “Unknown event condition 199”, then HC died, with a TB4 dock and two displays
Date: Fri, 20 Nov 2026 08:12:02 +0100	[thread overview]
Message-ID: <20261120071202.GH229695@black.igk.intel.com> (raw)
In-Reply-To: <CAMcR36KcP7cMZ2D1pu_bC-R0uPn2chd_1jEzp4FBBq-jZz=D3A@mail.gmail.com>

Hi,

On Thu, Nov 19, 2026 at 11:35:28AM -0800, Phani Kumar wrote:
> Hey,
> 
> Thanks for the reply. I did a few more tests to figure out this
> problem, and below is what I found.
> 
> Summary: the failure only happens on Linux when the USB4 link to the
> dock runs at Gen 3 (2 x 20 Gb/s). At Gen 2 (20 Gbps cable) Linux is
> stable. Windows 11 on the same laptop is stable at both Gen 2 and
> Gen 3, under the same load, with no USB/USB4/network errors logged.
> When it fails on Linux, the tunneled USB 3 link is stuck in Recovery
> at both USB 3 adapters while all tunnels stay up and the thunderbolt
> driver logs nothing.
> 
> == Hub 2-3 port 2 ==
> 
> Nothing USB 3 is enumerated behind 2-3 port 2 in my setup. In all
> these tests the displays are connected to the dock's downstream USB-C
> ports with video-only cables (one USB-C to HDMI, one USB-C to
> DisplayPort). Unplugging doesn't help: with no displays and only a
> USB 3 thumb drive on the dock, the failure still happens. In the
> latest run (7.4-rc3, usbcore.dyndbg=+p, both displays connected) I see
> no 2-x-portN warm reset messages before the failure, so the port 2
> resets do not seem to be required for it.
> 
> == Test matrix ==
> 
> Same laptop (Framework Laptop 13 Pro, Core Ultra X7 358H, BIOS 03.02),
> same Razer TB4 Dock (NVM 30.0), same displays (2560x1440@60 and @75).
> Dock always links in USB4 mode (sysfs generation 4).
> 
>   Cable                  Link                 Linux     Windows 11
>   TB4 cable x3           Gen 3, 2 x 20 Gb/s   fails     stable
>   USB4 40Gbps cable      Gen 3, 2 x 20 Gb/s   fails     stable
>   USB4 20Gbps cable x2   Gen 2, 2 x 10 Gb/s   stable    stable
> 
> Linux: kernels 7.3.3 and 7.4-rc3, every laptop port. Any USB 3 device
> behind the dock triggers it (RTL8153 or a thumb drive). When the xHC
> dies, USB 3 on all of the laptop's own ports goes down too; removing
> and rescanning 0000:00:0d.0 restores it.
> 
> Windows stress test (TB4 cable, "40Gbps/40Gbps (Gen 3, dual lane)",
> dock connected at boot, both displays): 20 GB download through the
> dock's RTL8153 at ~800 Mbps, USB 3 thumb drive on the dock at 146 MB/s
> read and 45-68 MB/s write, and both at the same time. No drops. The
> System event log has no USB, USB4, xHCI or network errors, only two
> "monitor ... successfully enumerated by the USB4 Connection Manager"
> entries at boot.
> 
> Control test without USB4: the USB-C monitor's hub (0bda:0412 +
> RTL8153) connected directly to the laptop as native USB 3 at 5 Gbps,
> same xHC: stable under heavy Ethernet traffic.
> 
> == USB 3 adapters stuck in Recovery ==
> 
> USB4 register snapshots (debugfs regs, tbadapters, tbtunnels) at
> Gen 2, at Gen 3 before the failure, and at Gen 3 after it
> (usb4-snapshots.tar.xz, including diff-report.txt):
> 
>   tbadapters            Gen 3 before    Gen 3 after failure
>   host 0:12 USB3 Down       U0              Recovery
>   dock 1:16 USB3 Up         U0              Recovery
>   tbtunnels: identical before and after, all tunnels present
> 
> Timeline (7.4-rc3): transfer errors at 70.3 s, event 199 for slot 8
> ep 3 at 78.0 s, "HC died" at 88.7 s. With thunderbolt.dyndbg=+p the
> thunderbolt driver logged nothing between 44 s and 138 s (no hotplug,
> notifications or link events). Vendor-specific registers on both USB 3
> adapters jump across the failure (e.g. 0x00000909 -> 0x0000b6b6 /
> 0x0011bcbc), and lane adapter cap 0x01 dword 2 goes from 0x7/0x3 to
> 0x0 on both ends.
> 
> == Lane margining ==
> 
> thunderbolt.ko rebuilt for 7.4-rc3 with USB4_DEBUGFS_WRITE and
> MARGINING, 3 runs per rate, raw debugfs results included
> (margining.tar.xz):
> 
>   Receiver                     Gen 2                  Gen 3
>   dock 1:1 voltage low/high    ~207/197 mV (at max)   ~77/75 mV
>   dock 1:1 lane 1 time (raw)   354-370 mUI            241-290 mUI
>   host retimer 1-0:1.1 time    387-403 mUI            370-403 mUI
>   host retimer voltage         (not readable)         ~107-121 mV
>   host router port 1 (SW)      0 errors               0 errors
> 
> So every receiver has margin at Gen 3, but the laptop -> dock
> direction (dock receiver) has noticeably less than dock -> laptop.
> Host retimer 8087:0d9c NVM 28.02 (fwupd), no newer firmware offered;
> BIOS 03.02 is the latest.
> 
> == Ruled out ==
> 
> - Bandwidth: USB 3 tunnel gets 9003/9003 Mb/s at Gen 3 (fails) but
>   only 9003/4751 Mb/s at Gen 2 (stable). xHCI port_bandwidth SS_BW is
>   ~90% available at both.
> - Thunderbolt 3 compatibility mode: both rates link as USB4
>   (generation 4).
> - thunderbolt.clx=0, bw_alloc_mode=0, pcie_aspm=off, runtime PM off on
>   0d.0/.2/.3, LPM/autosuspend off on the RTL8153, Realtek's r8152
>   v2.22.1: no effect. host_reset=Y.
> 
> == Questions ==
> 
> 1. Since Windows' CM keeps the Gen 3 link and the USB 3 tunnel clean on
>    the same hardware, what could Linux be configuring differently at
>    Gen 3 (TMU mode, lane/retimer equalization, USB 3 adapter setup)?

Windows CM should follow the CM guide as does Linux. USB3 tunnels are the
same regardless of the Gen, except that the isoc bandwidth limit is put
lower in case of Gen2.

> 2. Are ~75 mV / ~0.26 UI at the dock's receiver typical for Gen 3?

It's a good question. The hardware margin has bit set when these exceed the
ranges and in your case they are not set, also the host direction you don't
see errors so I would say this is okay.

> 3. Should r8152 back off after -EPROTO instead of resubmitting
>    immediately? That seems to be what pushes the xHC over in case 1.

For this I hope Mathias has an answer :)

  parent reply	other threads:[~2026-11-20  7:12 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CAMcR36+hWzhS_Pytej3uoDvOU6160v5vtuWXSnyFb=zEoRFQJQ@mail.gmail.com>
2026-11-04 12:10 ` xhci_hcd 0000:00:0d.0 (Panther Lake, 8086:e431): “Unknown event condition 199”, then HC died, with a TB4 dock and two displays Mika Westerberg
2026-11-10  9:08 ` Mathias Nyman
     [not found]   ` <CAMcR36LCr0RFrHsLFPaPziPS=1CMbEnO3GcDk=3Oe33S8uZFpw@mail.gmail.com>
2026-11-12 14:55     ` Mathias Nyman
     [not found]       ` <CAMcR36KcP7cMZ2D1pu_bC-R0uPn2chd_1jEzp4FBBq-jZz=D3A@mail.gmail.com>
2026-11-20  7:12         ` Mika Westerberg [this message]
2026-11-20 10:30           ` [WARNING: UNSCANNABLE EXTRACTION FAILED]Re: " Michal Pecio

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20261120071202.GH229695@black.igk.intel.com \
    --to=mika.westerberg@linux.intel.com \
    --cc=linux-usb@vger.kernel.org \
    --cc=mathias.nyman@linux.intel.com \
    --cc=phanigudipally@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.