Disabling or isolating failing hardware on Thinkpad X1 Extreme

OK I found a solution after some digging and heavy LLM guidance lol. I’ll type it here for posterity in case anyone else is stymied by the same incredibly niche issue, and to avoid a DenverCoder9-style tragedy as depicted in xkcd.

The card was indeed physically dead, and causing huge boot delays and instability.

lspci | grep -i nvidia

The card was listed in PCI bus…

dmesg | grep -i nvidia

…but showed a definitive hardware failure with the following lines:

NVRM: GPU 0000:01:00.0: RmInitAdapter failed! (0x24:0x72:1590)

nvidia 0000:01:00.0: not ready 65535ms after resume; giving up

Failed to enable MSI; request_irq() failed (-22)

VC save buffer size does not match

These indicate initialization failure, unresponsiveness to PCI commands, inability to handle interrupts, broken virtual channel communication. In other words, well and truly toasted.

I initially tried to use driverctl (found in AUR) but the problem was that it ran as a systemd service, which executes after the initramfs has already loaded nvidia (via the kms hook). By that point, nvidia has already claimed the GPU. Blacklisting or uninstalling nvidia stuff won’t be useful here because I want the nvidia eGPU to connect.

I created a script @ /usr/local/bin/vfio-pci-override.sh

#!/bin/sh

DEVS=“0000:01:00.0 0000:01:00.1”

for DEV in $DEVS; do
if [ -e /sys/bus/pci/devices/$DEV ]; then
echo “vfio-pci” > /sys/bus/pci/devices/$DEV/driver_override
fi
done

modprobe -i vfio-pci

Then applied chmod +x to it. Note that 0000.01.00.0 etc may be different on your own system, check with lspci.

Hooked the script into modconf with a file @ /etc/modprobe.d/vfio.conf

install vfio-pci /usr/local/bin/vfio-pci-override.sh

Updated /etc/mkinitcpio.conf with the following lines:

  • FILES=(/usr/local/bin/vfio-pci-override.sh)
    
  • Added vfio_pci vfio vfio_iommu_type1 to MODULES=( before any nvidia driver

  • Checked modconf was in HOOKS=(

sudo mkinitcpio -P

Then also replied y to limine as I’m using it.

The Lenovo Graphics Dock with the external GTX 1050 did not require any configuration and worked out of the box with whatever drivers CachyOS installed.

  1. Boot starts → initramfs loads

  2. vfio-pci module requested → script runs first

  3. Script writes vfio-pci to /sys/bus/pci/devices/0000:01:00.0/driver_override

  4. nvidia loads → tries to probe 01:00.0 → kernel blocks it (override set)

  5. External dock plugged in → appears on different PCI address (Thunderbolt bus, e.g., 09:00.0)

  6. nvidia binds to external GPU → works normally (no override on that address)