Hi Suse Forums! I am trying to follow this (https://wiki.archlinux.org/index.php/PCI_passthrough_via_OVMF) guide from the Arch wiki to set up a virtual machine with GPU passthrough on OpenSuse. Things are going well, except I can’t quite figure out how to properly set up the initrd. The OpenSuse official documentation seems outdated and suggests using mkinitrd to do this, however, after some googling I’ve found that this has been replaced with Dracut in recently.
What is the proper way, using Dracut, to set up an initrd with the following options outlined in the Arch wiki, and set grub to point to the appropriate initrd?
Alternatively, is there any other way to have the vfio module ‘claim’ my GPU before the FGLRX or Radeon drivers would, so that it is available for passthrough? Any help/suggestions is much appreciated! Thank you!
mkinitrd still exists and works. In particular, INITRD_MOULES in /etc/sysconfig/kernel still works.
What is the proper way, using Dracut, to set up an initrd with the following options outlined in the Arch wiki, and set grub to point to the appropriate initrd?
You can use “force_drivers” dracut configuration variable to add kernel modules to unconditionally load in initrd and “omit_drivers” to prevent kernel modules to be added.
Alternatively, is there any other way to have the vfio module ‘claim’ my GPU before the FGLRX or Radeon drivers would, so that it is available for passthrough?
There’s not only a lot of information, there are several scenarios described in your reference link.
Also, be prepared for practically all guides and documentation relating to hardware pass-through to be outdated, nowadays things literally change by the day.
IMO the Arch Wiki page you reference gets ahead of itself a little…
You should first start by searching on the kernel modules you need to see if they’re already built and available so you don’t have to re-build and create a new initrd. If the modules are already built, then you can load the module when appropriate (It looks like you may want to load your modules on boot, so passing commands during your Grub boot is a likely candidate).
In fact,
Despite what is stated in earlier sections, as you work your way down the page, various sections confirm my suspicion that any kernel 4.1.x or later likely has those kernel modules already available (although you should double-check to make sure none were removed by our maintainers for their own reasons).
Note also that despite the Prerequisites listed at the top of your reference, further down the page exceptions and workarounds to some of those prerequisites are described.
And, of course the page describes several other types of hardware pass-through which explains why many of the “prequisite modules” like the various virtio are listed… Because AFAIK those aren’t related to GPU pass through.