Using Ubuntu MATE and through Virtual Machine Manager I was able to successfully pass through the iGPU of my 11600k to a VM. As the title alludes, once I shutdown the VM I am logged out completely with all my windows closed. Anyone have any thoughts on this?
I don’t know if this is related, but double-check Virtualization settings in BIOS. Additionally make sure Memory Protection is enabled. Both of those are under Security on my laptop, but may be somewhere else.
The only time I messed with it it seemed to prevent signals from crossing between VMs and the underlying system. In my case it was running shutdown in a VM would shut down the whole box. I don’t know if it ties into your issue, but it might be worth a shot.
I’ve had this problem when the passed-through GPU wasn’t properly hidden from my host. Do you have a dedicated GPU for your host or are you sharing the iGPU and doing single GPU passthrough?
I haven’t tried this with an Intel iGPU but here is my “scorched earth” approach to isolating a GPU for pass through:
Make sure the vfio_pci.ids= are set appropriately in the kernel command line
Add vfio_pci.disable_vga=1 to the command line
Make sure vfio_pci loads early…
How exactly to do this will vary by operating system; in Debian/Ubuntu I add these lines to my /etc/initramfs-tools/modules file:
vfio
vfio_iommu_type1
vfio_pci
vfio_virqfd
Make sure PCI Express Graphics is set to the primary display output in the BIOS, otherwise you might have to add video=efifb:off to the command line
Add module_blacklist= to the command line with the appropriate Linux drivers that you want to prevent loading, e.g.:
nouveau for NVIDIA
amdgpu for AMD
I don’t know what it is for Intel and my only system with an Intel iGPU is offline right now… maybe i915?
Don’t forget to update the initramfs (in Debian/Ubuntu, update-initramfs -k all -u) and grub configuration (in Debian/Ubuntu, update-grub).
Obviously this only works if you have two different brands of GPU. And it’s probably overkill… you may not need all these steps and there may be lighter-touch ways to accomplish the same results. But if this “fixes” the problem you at least have a known-good place to start and work backward from. Good luck!
ETA: I think the alternative approach is to hide the passed-through GPU from the display manager instead of trying to hide it from the operating system, so keep that in mind if you’re looking for another angle to crack this nut.
Another way is to blacklist the PCIe devices manually. You can test if it helps first by writing 1 tothe remove character device assosicated with it under sysfs