qemu: Add command line for IOMMUFD

For each IOMMUFD device create an object and assign
it to the device, we need additional information that
is populated now correctly to decide if we run the old VFIO
or new VFIO backend.

Signed-off-by: Zvonko Kaiser <zkaiser@nvidia.com>
This commit is contained in:
Zvonko Kaiser
2025-01-15 21:16:52 +00:00
parent e82fdee20f
commit 9add633258
5 changed files with 18 additions and 2 deletions

View File

@@ -792,7 +792,7 @@ func (q *qemu) createPCIeTopology(qemuConfig *govmmQemu.Config, hypervisorConfig
return fmt.Errorf("Cannot get host path for device: %v err: %v", dev, err)
}
vfioDevices := []*config.VFIODev{}
var vfioDevices []*config.VFIODev
// This works for IOMMUFD enabled kernels > 6.x
// In the case of IOMMUFD the device.HostPath will look like
// /dev/vfio/devices/vfio0