[vfio-users] issues about igd-passthrough using vfio-pci

fulaiyang fulaiyang at 163.com
Wed Sep 14 02:37:06 UTC 2016


hello,
    Thanks for your reply and sorry to provide not enough information.
    The IGD is the the primary graphics on the host and I am trying to do  legacy mode. The VM is SeaBIOS based and the system is a a desktop. My configuration is as follows:


environment :
Intel Core i3-6100U @ 2.30GHz
Intel Corporation Sky Lake Integrated Graphics 
Ubuntu 16.04 LTS DESKTOP
Host kernel 4.6.6 x86_64 GNU/Linux
qemu 2.7.0


configuration:
/boot/config-4.6.6
    CONFIG_VFIO_IOMMU_TYPE1=m
    CONFIG_VFIO=m
    CONFIG_VFIO_PCI=m
    CONFIG_VFIO_PCI_IGD=y
    CONFIG_VFIO_PCI_VGA=y
    CONFIG_FW_CFG_SYSFS=y 
    CONFIG_FW_CFG_SYSFS_COMLINE=y
    CONFIG_INTEL_IOMMU_DEFAULT_ON=y
/boot/grub/grub.cfg
            /boot/vmlinuz-4.6.6 root=… quiet splash intel_iommu=on vfio_iommu_type1.allow_unsafe_interrupts=1 $vt_handoff modprobe.blacklist=i915 video=vesafb:off video=efifb:off  
modprobe vfio-pci vfio vfio_iommu_type1 pci_stub
dmesg
[    0.000000] DMAR: IOMMU enabled
[    0.079101] DMAR: Host address width 39
[    0.079103] DMAR: DRHD base: 0x000000fed90000 flags: 0x0
[    0.079114] DMAR: dmar0: reg_base_addr fed90000 ver 1:0 cap 1c0000c40660462 ecap 7e3ff0505e
[    0.079116] DMAR: DRHD base: 0x000000fed91000 flags: 0x1
[    0.079121] DMAR: dmar1: reg_base_addr fed91000 ver 1:0 cap d2008c40660462 ecap f050da
[    0.079123] DMAR: RMRR base: 0x0000008714a000 end: 0x00000087169fff
[    0.079125] DMAR: RMRR base: 0x00000088800000 end: 0x0000008cffffff
[    0.079127] DMAR: ANDD device: 9 name: \_SB.PCI0.UA00
[    0.079129] DMAR-IR: IOAPIC id 2 under DRHD base  0xfed91000 IOMMU 1
[    0.079131] DMAR-IR: HPET id 0 under DRHD base 0xfed91000
[    0.079132] DMAR-IR: x2apic is disabled because BIOS sets x2apic opt out bit.
[    0.079134] DMAR-IR: Use 'intremap=no_x2apic_optout' to override the BIOS setting.
[    0.080772] DMAR-IR: Enabled IRQ remapping in xapic mode
[    7.224820] DMAR: ACPI device "device:56" under DMAR at fed91000 as 00:1e.0
[    7.224831] DMAR: No ATSR found
[    7.225085] DMAR: dmar0: Using Queued invalidation
[    7.225091] DMAR: dmar1: Using Queued invalidation
[    7.225257] DMAR: Hardware identity mapping for device 0000:00:00.0
[    7.225264] DMAR: Hardware identity mapping for device 0000:00:02.0
[    7.225266] DMAR: Hardware identity mapping for device 0000:00:08.0
[    7.225268] DMAR: Hardware identity mapping for device 0000:00:14.0
[    7.225270] DMAR: Hardware identity mapping for device 0000:00:16.0
[    7.225272] DMAR: Hardware identity mapping for device 0000:00:17.0
[    7.225274] DMAR: Hardware identity mapping for device 0000:00:1d.0
[    7.225276] DMAR: Hardware identity mapping for device 0000:00:1d.1
[    7.225278] DMAR: Hardware identity mapping for device 0000:00:1e.0
[    7.225279] DMAR: Hardware identity mapping for device 0000:00:1f.0
[    7.225281] DMAR: Hardware identity mapping for device 0000:00:1f.2
[    7.225283] DMAR: Hardware identity mapping for device 0000:00:1f.3
[    7.225285] DMAR: Hardware identity mapping for device 0000:00:1f.4
[    7.225288] DMAR: Hardware identity mapping for device 0000:01:00.0
[    7.225292] DMAR: Hardware identity mapping for device 0000:02:00.0
[    7.225294] DMAR: Hardware identity mapping for device 0000:00:1e.0
[    7.225295] DMAR: Setting RMRR:
[    7.225297] DMAR: Ignoring identity map for HW passthrough device 0000:00:02.0 [0x88800000 - 0x8cffffff]
[    7.225299] DMAR: Ignoring identity map for HW passthrough device 0000:00:14.0 [0x8714a000 - 0x87169fff]
[    7.225300] DMAR: Prepare 0-16MiB unity mapping for LPC
[    7.225302] DMAR: Ignoring identity map for HW passthrough device 0000:00:1f.0 [0x0 - 0xffffff]
[    7.225320] DMAR: Intel(R) Virtualization Technology for Directed I/O
[    7.868474] DMAR: 32bit 0000:02:00.0 uses non-identity mapping
[   11.026811] DMAR: 32bit 0000:01:00.0 uses non-identity mapping
[62353.718698] DMAR: DRHD: handling fault status reg 2
[62353.718705] DMAR: [DMA Write] Request device [00:02.0] fault addr 0 [fault reason 02] Present bit in context entry is clear
[62365.445003] DMAR: DRHD: handling fault status reg 2
[62365.445014] DMAR: [DMA Write] Request device [00:02.0] fault addr 0 [fault reason 02] Present bit in context entry is clear
lspci -nks 00:02.0
00:02.0 0300: 8086:1906 (rev 07)
Subsystem: 1b0a:01c6
Kernel driver in use: vfio-pci
Kernel modules: i915
qemu cmdline bash
#!/bin/bash
sudo /home/pengqian/build/x86_64-softmmu/qemu-system-x86_64 \
-name pq \
-boot order=dc \
-cpu host \
-machine pc,accel=kvm,usb=off \
-m 4096 \
-smp 4,sockets=1,cores=4,threads=1 \
-device vfio-pci,host=00:02.0,id=hostdev0,bus=pci.0,addr=0x2 \
-nographic \
-vga none \
-drive file=/home/pengqian/win7.base,if=none,id=drive-virtio-disk0,format=qcow2,cache=writeback \
-device virtio-blk-pci,scsi=off,drive=drive-virtio-disk0 \
-netdev user,id=hostnet0 \
-device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:1a:0d:64 \
-device usb-ehci,id=ehci0 \
-device usb-tablet,id=input0 \
-device intel-hda,id=sound0 \
-monitor tcp:172.21.136.8:4444,server,nowait \
-device hda-micro,id=sound0-codec0,bus=sound0.0,cad=0 \


sorry to my poor English.
                                                                                                                                                                                                                                                                                   yangfulai







在 2016-09-14 09:33:08,"Alex Williamson" <alex.l.williamson at gmail.com> 写道:

On Tue, Sep 13, 2016 at 6:59 PM, fulaiyang <fulaiyang at 163.com> wrote:
thank you,I also have tried many ways but it still didn't work. I want to know what kind of gpu vfio support?


You haven't really provided enough information to begin to help.  Are you trying to do legacy mode or UPT for the GPU?  What's the QEMU command line or XML for the VM?  Is IGD the primary graphics on the host?   What are the CONFIG_VFIO_* options in the host kernel?  Is the VM SeaBIOS based or OVMF?  Is the system a laptop or a desktop?  The less you can make trying to help you a game of 20 question, the more help you're potentially going to get.  Output to a monitor or laptop screen requires opregion support, which generally works, but is not something Intel officially claims support for with UPT mode.  I don't know why an i3-6100U would be unique, but I only have a handful of devices to test and that processor is not among them.  Thanks,


Alex
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/vfio-users/attachments/20160914/57272936/attachment.htm>


More information about the vfio-users mailing list