https://wiki.archlinux.org/title/Intel_GVT-g
only works with Intel Broadwell (5th gen) to Comet Lake (10th gen)
For Xe Architecture (Gen12) based GPUs, SR-IOV feature is needed instead.
For KVMGT, you also can use the current upstream Linux kernel and QEMU directly since all the enabling patches have been upstreamed.
https://github.com/intel/gvt-linux/tree/gvt-staging/drivers/gpu/drm/i915/gvt
vi /etc/default/grub # KVMGT
i915.hvm_boot_foreground=1 i915.enable_gvt=1 kvm.ignore_msrs=1 intel_iommu=igfx_off drm.debug=0
mdev
ls /sys/bus/pci/devices/0000\:00\:02.0/mdev_supported_types/
V4 means it is "Broadwell" platform,
V5 means it is "Skylake" or "Kabylake" platform
vgpu_create="/sys/bus/pci/devices/0000:00:02.0/mdev_supported_types/i915-GVTg_V5_4/create"
echo "a297db4a-f4c2-11e6-90f6-d3b88d6c9525" > $vgpu_create
ls /sys/bus/pci/devices/0000:00:02.0/
/sys/bus/pci/devices/0000:00:02.0/mdev_supported_types/i915-GVTg_V5_4/description
low_gm_size: 128MB
high_gm_size: 512MB
fence: 4
resolution: 1920x1200
weight: 4
/sys/bus/pci/devices/0000:00:02.0/mdev_supported_types/i915-GVTg_V5_8/description
low_gm_size: 64MB
high_gm_size: 384MB
fence: 4
resolution: 1024x768
weight: 2