[vfio-users] How to spoof device (sub)class ID for passthrough devices?

Björn Ruytenberg bjorn at bjornweb.nl
Sat Feb 9 13:38:35 UTC 2019


Hi,

I am looking for a way to spoof the PCI Device (sub)class ID for
passthrough devices. The following returns a nice list of options (on
QEMU 2.11.1), but I can't seem to find one that does just that:

$ qemu-system-x86_64 -device vfio-pci,? 2>&1 | grep "x-*"
vfio-pci.x-pci-sub-device-id=uint32
vfio-pci.x-no-kvm-msi=bool
vfio-pci.x-pcie-lnksta-dllla=bool (on/off)
vfio-pci.x-igd-opregion=bool (on/off)
vfio-pci.x-vga=bool (on/off)
vfio-pci.x-pci-vendor-id=uint32
vfio-pci.x-req=bool (on/off)
vfio-pci.x-igd-gms=uint32
vfio-pci.x-no-kvm-intx=bool
vfio-pci.x-pci-device-id=uint32
vfio-pci.host=str (Address (bus/device/function) of the host device,
example: 04:10.0)
vfio-pci.x-no-kvm-msix=bool
vfio-pci.x-intx-mmap-timeout-ms=uint32
vfio-pci.bootindex=int32
vfio-pci.x-pcie-extcap-init=bool (on/off)
vfio-pci.addr=int32 (Slot and optional function number, example: 06.0 or 06)
vfio-pci.x-pci-sub-vendor-id=uint32
vfio-pci.x-nv-gpudirect-clique=uint4 (NVIDIA GPUDirect Clique ID (0 - 15))
vfio-pci.x-no-mmap=bool


Is it possible to spoof PCI device class ID? Otherwise, any pointers
where it can be patched (if possible) will be much appreciated!

-- 
Kind regards,
Björn Ruytenberg
https://bjornweb.nl




More information about the vfio-users mailing list