[vfio-users] Intel 520 Integrated Graphics Card Passthrough Issues

Jeff Tchang jeff.tchang at gmail.com
Tue Jun 30 17:00:31 UTC 2020


Yay! Got it to work. My issue was that it wasn't in slot 0x02.
I changed
      <address type="pci" domain="0x0000" bus="0x00" slot="0x08"
function="0x0"/>
to
      <address type="pci" domain="0x0000" bus="0x00" slot="0x02"
function="0x0"/>
.

Thanks!

Jeff

On Tue, Jun 30, 2020 at 9:48 AM Jeff Tchang <jeff.tchang at gmail.com> wrote:

>
> when you reach the desktop your video card will be handled by probably
>> fbdev and you will be told that you are running in an unaccelerated video
>> mode and things might be slow.
>> this is why i used to use xfce4 for my desktop.
>>
>
> I don't have a desktop since running in headless mode.
>
>
>> it works faster faster with fbdev (fbdev is basically VESA mode from the
>> days of DOS).
>>
>> make sure the integrated gpu is owned by the vfio-pci driver after
>> booting.
>> >lspci -nnk | grep -i vga -A 6
>>
>>
> # lspci -nnk | grep -i vga -A 6
>
> 00:02.0 *VGA* compatible controller [0300]: Intel Corporation Skylake GT2
> [HD Graphics 520] [8086:1916] (rev 07)
>
> DeviceName:  CPU
>
> Subsystem: Intel Corporation Skylake GT2 [HD Graphics 520] [8086:2063]
>
> Kernel driver in use: vfio-pci
>
> Kernel modules: i915
>
> Looks like it is loaded to me.
>
> # dmesg | grep -i vfio
>
> [    0.000000] Command line: BOOT_IMAGE=/boot/vmlinuz-5.4.0-39-generic
> root=UUID=e7830f59-8c35-4d97-8315-6e3e93a4075f ro intel_iommu=on nomodeset
> nofb rd.driver.pre=*vfio*-pci video=efifb:off,vesafb:off simplefb=off
> modprobe.blacklist=i915 pcie_acs_override=downstream iommu=pt *vfio*
> -pci.ids=8086:1916
>
> [    0.081894] Kernel command line:
> BOOT_IMAGE=/boot/vmlinuz-5.4.0-39-generic
> root=UUID=e7830f59-8c35-4d97-8315-6e3e93a4075f ro intel_iommu=on nomodeset
> nofb rd.driver.pre=*vfio*-pci video=efifb:off,vesafb:off simplefb=off
> modprobe.blacklist=i915 pcie_acs_override=downstream iommu=pt *vfio*
> -pci.ids=8086:1916
>
> [    0.523948] *VFIO* - User Level meta-driver version: 0.3
>
> [    0.524053] *vfio*-pci 0000:00:02.0: vgaarb: changed VGA decodes:
> olddecodes=io+mem,decodes=io+mem:owns=io+mem
>
> [    0.542711] *vfio*_pci: add [8086:1916[ffffffff:ffffffff]] class
> 0x000000/00000000
>
> When starting the virtual machine the screen blanks and there is no
> signal. I see dmesg output as follows:
>
> [  412.472468] DMAR: DRHD: handling fault status reg 2
>
> [  412.472477] DMAR: [DMA Write] Request device [00:02.0] PASID ffffffff
> fault addr 0 [fault reason 02] Present bit in context entry is clear
>
> [  412.472553] DMAR: DRHD: handling fault status reg 3
>
> [  412.472557] DMAR: [DMA Read] Request device [00:02.0] PASID ffffffff
> fault addr 7c000000 [fault reason 06] PTE Read access is not set
>
> [  412.472562] DMAR: DRHD: handling fault status reg 3
>
> [  412.472566] DMAR: [DMA Read] Request device [00:02.0] PASID ffffffff
> fault addr 7c02a000 [fault reason 06] PTE Read access is not set
>
> [  412.473623] DMAR: DRHD: handling fault status reg 3
>
> [  412.933155] vfio-pci 0000:00:02.0: vfio_ecap_init: hiding ecap
> 0x1b at 0x100
>
> <domain type="kvm">
>   <name>fedora-2</name>
>   <uuid>3bc39504-8455-4156-b4a0-7f27e5d89ae1</uuid>
>   <metadata>
>     <libosinfo:libosinfo xmlns:libosinfo="
> http://libosinfo.org/xmlns/libvirt/domain/1.0">
>       <libosinfo:os id="http://fedoraproject.org/fedora/unknown"/>
>     </libosinfo:libosinfo>
>   </metadata>
>   <memory unit="KiB">2097152</memory>
>   <currentMemory unit="KiB">2097152</currentMemory>
>   <vcpu placement="static">2</vcpu>
>   <os>
>     <type arch="x86_64" machine="pc-i440fx-4.2">hvm</type>
>     <boot dev="hd"/>
>   </os>
>   <features>
>     <acpi/>
>     <apic/>
>     <vmport state="off"/>
>   </features>
>   <cpu mode="host-model" check="partial"/>
>   <clock offset="utc">
>     <timer name="rtc" tickpolicy="catchup"/>
>     <timer name="pit" tickpolicy="delay"/>
>     <timer name="hpet" present="no"/>
>   </clock>
>   <on_poweroff>destroy</on_poweroff>
>   <on_reboot>restart</on_reboot>
>   <on_crash>destroy</on_crash>
>   <pm>
>     <suspend-to-mem enabled="no"/>
>     <suspend-to-disk enabled="no"/>
>   </pm>
>   <devices>
>     <emulator>/usr/bin/qemu-system-x86_64</emulator>
>     <disk type="file" device="disk">
>       <driver name="qemu" type="qcow2"/>
>       <source file="/var/lib/libvirt/images/fedora-2.qcow2"/>
>       <target dev="vda" bus="virtio"/>
>       <address type="pci" domain="0x0000" bus="0x00" slot="0x07"
> function="0x0"/>
>     </disk>
>     <disk type="file" device="cdrom">
>       <driver name="qemu" type="raw"/>
>       <target dev="sda" bus="sata"/>
>       <readonly/>
>       <address type="drive" controller="0" bus="0" target="0" unit="0"/>
>     </disk>
>     <controller type="usb" index="0" model="qemu-xhci" ports="15">
>       <address type="pci" domain="0x0000" bus="0x00" slot="0x04"
> function="0x0"/>
>     </controller>
>     <controller type="pci" index="0" model="pci-root"/>
>     <controller type="sata" index="0">
>       <address type="pci" domain="0x0000" bus="0x00" slot="0x05"
> function="0x0"/>
>     </controller>
>     <controller type="virtio-serial" index="0">
>       <address type="pci" domain="0x0000" bus="0x00" slot="0x06"
> function="0x0"/>
>     </controller>
>     <interface type="network">
>       <mac address="52:54:00:29:7f:c2"/>
>       <source network="default"/>
>       <model type="virtio"/>
>       <address type="pci" domain="0x0000" bus="0x00" slot="0x02"
> function="0x0"/>
>     </interface>
>     <serial type="pty">
>       <target type="isa-serial" port="0">
>         <model name="isa-serial"/>
>       </target>
>     </serial>
>     <console type="pty">
>       <target type="serial" port="0"/>
>     </console>
>     <channel type="unix">
>       <target type="virtio" name="org.qemu.guest_agent.0"/>
>       <address type="virtio-serial" controller="0" bus="0" port="1"/>
>     </channel>
>     <channel type="spicevmc">
>       <target type="virtio" name="com.redhat.spice.0"/>
>       <address type="virtio-serial" controller="0" bus="0" port="2"/>
>     </channel>
>     <input type="tablet" bus="usb">
>       <address type="usb" bus="0" port="1"/>
>     </input>
>     <input type="mouse" bus="ps2"/>
>     <input type="keyboard" bus="ps2"/>
>     <sound model="ich9">
>       <address type="pci" domain="0x0000" bus="0x00" slot="0x03"
> function="0x0"/>
>     </sound>
>     <hostdev mode="subsystem" type="pci" managed="yes">
>       <source>
>         <address domain="0x0000" bus="0x00" slot="0x02" function="0x0"/>
>       </source>
>       <rom bar="on" file="IntelUHD520.bin"/>
>       <address type="pci" domain="0x0000" bus="0x00" slot="0x08"
> function="0x0"/>
>     </hostdev>
>     <memballoon model="virtio">
>       <address type="pci" domain="0x0000" bus="0x00" slot="0x09"
> function="0x0"/>
>     </memballoon>
>     <rng model="virtio">
>       <backend model="random">/dev/urandom</backend>
>       <address type="pci" domain="0x0000" bus="0x00" slot="0x0a"
> function="0x0"/>
>     </rng>
>   </devices>
> </domain>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/vfio-users/attachments/20200630/a2cf813b/attachment.htm>


More information about the vfio-users mailing list