xhci: Gen2 root port links reported as SuperSpeed when port capabilities have different PSI tables

From
Anton Bulakh <hidden>
Date
2026-10-30 19:19:06
Hi Mathias,

Preface: I am not a kernel developer and this was obviously LLM work, but I am capable of reading and basic reasoning *before* sending up a report and I believe this is real, especially as I was part of the loop in testing it with the devices I had at hand and running sudo commands.

Additionally, I had it search for similar bug reports and this was not reported yet seemingly (it searched way more than I ever could've myself).

The LLM wrote:

On an AMD X570 board (Gigabyte X570 I AORUS PRO WIFI, chipset xHCI 1022:149c), devices on the two Gen2-capable root ports always show up as "new SuperSpeed USB device" with speed 5000, but the link is 10 Gbps. Seen on 6.18.55; the code is the same in mainline and for-usb-next.

The controller has four USB 3.1 Supported Protocol capabilities with one port each, and different PSI tables (debugfs reg-ext-protocol):

  cap  PORTINFO    port  PSI
  01   0x10000107  7     0x00050134 (ID 4, 5 Gb/s)
  02   0x10000108  8     0x00050134
  03   0x20000109  9     0x00050134, 0x000a4135 (ID 5, 10 Gb/s SSP)
  04   0x2000010a  10    0x00050134, 0x000a4135

PORTSC of ports 9 and 10 with Gen2 devices connected:

  0x00001603 Powered Connected Enabled Link:U0 PortSpeed:5

xhci_create_usb3x_bos_desc() builds the root hub SSP capability from one port_cap only: the first one with the highest revision. All four are 3.1, so it uses cap 01, which has only ID 4. get_port_ssp_rate() then finds no sublink speed attribute with ID 5, returns USB_SSP_GEN_UNKNOWN, and the device gets USB_SPEED_SUPER.

The link does run at Gen2. A SATA SSD and a USB flash drive behind a VL822 hub read 849 MB/s together with the hub on port 10, and 425 MB/s with the hub on a Gen1-only root port. Devices behind the hub are reported correctly as Gen 2x1, because the hub's own BOS lists 10 Gb/s.

A possible fix: build the root hub SSP capability from the PSIs of all USB 3.x port capabilities, with duplicate speed IDs merged (the PSIVs agree here).

This can also explain the 10 Gbps hub reported as 5 Gbps on an AMD root port in https://bugzilla.kernel.org/show_bug.cgi?id=218943.

(LLM out)

Feel free to ask for more info (I wouldn't know what else to provide) and I can test kernel patches if needed.

Thanks,
Anton
Thread (4 messages) 4 messages, 2 authors, last reply 16d ago
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help