[RESPONDED] GPU Passthrough works with an eGPU!

I was bored and wanted to test if I could use VFIO on the framework. Turns out it works, and the UX is actually pretty nice.

The main hassle of vfio is iommu groups, but I guess thanks to my eGPU board (ADT-link r43sg) and the framework motherboard, the gpu is in a group with only the Thunderbolt bridge it uses and its audio device (so I bound all three). evdev device passthrough and emulated sound.

Steps I followed and niceties now available:

  • fixed modules and bound the device to vfio following archwiki
  • installed Windows 11 in kvm, shut it down before network connecting it (installed without network via OOBE bypass)
  • added the PCI devices to the vm and removed all the other display/input devices I didn’t need
  • booted back up with windows showing on my egpu’s connected monitor!
    • if I bought a dummy plug, I could alternatively connect that monitor to my hdmi expansion card instead and use a client like Looking Glass to view it.

The best part, it’s hotplug as long as the kvm is currently shut down! If it’s not, the guest will crash to the point I had to reboot the host to reconnect to it. Since it’s just a pci device to Linux and not actually bound to any video drivers, it basically acts like a normal usb and isn’t subject to any of the same issues with screens suddenly appearing/disappearing.

3 Likes

Would we want to call this a guide? Feels like it could be guide-worthy.

3 Likes

Feel free to! I’ll clean it up soon if that’s the case, just originally wanted to post my surprising success with it.

I did do this on Arch, but I’m sure the archwiki steps could be adapted to Fedora by swapping in dracut for mkinitcpio and grub2-* for grub-*

Seeing “Thunderbolt bridge” instead of “USB4”, I’m assuming this is an Intel FW?

Yes, this was the 11th gen. There’s a script on the archwiki that will tell you what IOMMU group your egpu is in on other boards, and given this experience as long as the groups are something similar to mine, you’ll have no issues.