Skip to contentSkip to conversation

New: Kernel Oops in pcie_update_link_speed when hotplugging TB4 dock on x870e / kernel 6.14.0-rc7

Bug 219906 Bjorn Helgaas 3 participants 3 messages Mar 21, 2025 1 message not in the archive PCI

lore
Share & tools
lore
#1 lore raw
In reply to a message not in the archive
Quoted 22 lines · On Fri, Mar 21, 2025 at 06:30:40PM +0000, [email protected] wrote:

https://bugzilla.kernel.org/show_bug.cgi?id=219906

            Bug ID: 219906
           Summary: Kernel Oops in pcie_update_link_speed when hotplugging
                    TB4 dock on x870e / kernel 6.14.0-rc7

Created attachment 307878
--> https://bugzilla.kernel.org/attachment.cgi?id=307878&action=edit
dmesg output hotplugging dock

When connecting a Lenovo TB4 dock (40B0) using the USB4 port of an ASRock x870E Nova motherboard, Linux kernel 6.14.0-rc7 will Oops with a NULL pointer dereference.

This is 100% reproducible on my system and happens immediately when plugging the USB4 cable into the docking station. Interestingly, USB devices connected to the docking station still work, but displays connected to it will not. Also, after the kernel Oops the system is in some corrupted state, as things like mkinitcpio will hang at the autodetect hook when enumerating udev devices, and when shutting down the system will get stuck indefinitely on hanging udev_worker processes.

Quoted 8 lines

When booting the machine while the dock is already attached, the kernel boots without any apparent problems, but displays connected to the dock will still not show any image.

This dock has been working without any issue in combination with a different Linux laptop with USB4 and an AMD780M, a MacBook Pro, and a Windows 11 laptop.

Attached is the dmesg output after hot-plugging the dock.

Do you know whether this is a regression? Does any kernel work correctly on the system in question?

#2 lore raw
Quoted 9 lines · Bjorn Helgaas
Quoted 5 lines · On Fri, Mar 21, 2025 at 06:30:40PM +0000, [email protected] wrote:

https://bugzilla.kernel.org/show_bug.cgi?id=219906

            Bug ID: 219906
           Summary: Kernel Oops in pcie_update_link_speed when hotplugging
                    TB4 dock on x870e / kernel 6.14.0-rc7

Do you know whether this is a regression? Does any kernel work correctly on the system in question?

This is a regression caused by

commit 665745f274870c921020f610e2c99a3b1613519b
Author: Ilpo Järvinen <[email protected]>
Date: Fri Oct 18 17:47:52 2024 +0300

PCI/bwctrl: Re-add BW notification portdrv as PCIe BW controller

which went into v6.13-rc1. It can be overcome by duplicating

commit 62e4492c3063048a163d238cd1734273f2fc757d
Author: Andreas Noever <[email protected]>
Date: Mon Jun 9 23:03:32 2014 +0200

PCI: Prevent NULL dereference during pciehp probe

in the bandwidth controller driver.

I can submit a patch tomorrow unless you or Ilpo beat me to it. (Sorry, I'm still a little sleep deprived today after OSPM Summit.)

Thanks,

Lukas

#3 lore raw
In reply to Bjorn Helgaas

I don’t know if this is a kernel regression, the only kernel I have tried before 6.14.0-rc7 was the latest stable kernel (6.13.7) which had the same problem.

There might some interaction with the system BIOS though, which may also be bugged. On an earlier BIOS version I could at least get output on displays connected to the dock, despite getting similar kernel crashes and hanging udev_worker processes. With the new bios I cannot get any display output at all, not even for the UEFI boot screens or the Linux text console.

The dmesg output I posted is when plugging in the dock without any displays connected to it though, so something is already failing independent of any potential other issues related to displays.

-Wouter

Quoted 36 lines · Bjorn Helgaas
Quoted 22 lines · On Fri, Mar 21, 2025 at 06:30:40PM +0000, [email protected] wrote:

https://bugzilla.kernel.org/show_bug.cgi?id=219906

           Bug ID: 219906
          Summary: Kernel Oops in pcie_update_link_speed when hotplugging
                   TB4 dock on x870e / kernel 6.14.0-rc7

Created attachment 307878
--> https://bugzilla.kernel.org/attachment.cgi?id=307878&action=edit
dmesg output hotplugging dock

When connecting a Lenovo TB4 dock (40B0) using the USB4 port of an ASRock x870E Nova motherboard, Linux kernel 6.14.0-rc7 will Oops with a NULL pointer dereference.

This is 100% reproducible on my system and happens immediately when plugging the USB4 cable into the docking station. Interestingly, USB devices connected to the docking station still work, but displays connected to it will not. Also, after the kernel Oops the system is in some corrupted state, as things like mkinitcpio will hang at the autodetect hook when enumerating udev devices, and when shutting down the system will get stuck indefinitely on hanging udev_worker processes.

Quoted 8 lines

When booting the machine while the dock is already attached, the kernel boots without any apparent problems, but displays connected to the dock will still not show any image.

This dock has been working without any issue in combination with a different Linux laptop with USB4 and an AMD780M, a MacBook Pro, and a Windows 11 laptop.

Attached is the dmesg output after hot-plugging the dock.

Do you know whether this is a regression? Does any kernel work correctly on the system in question?