[vfio-users] pass-through gpu to guest, but only once?!

Fireball Firebomb Firebomb at gmx.de
Fri Sep 25 15:39:49 UTC 2015


Hi,
i have a patched kernel version 4.1.6-1 with the ACS override patch and 
i915 VGA arbiter patch and enabled them with the correct boot parameter.

I can pass-through my Nvidia card to the virtual machine (using 
seabios), but only once. After that I get an error message:
"qemu-system-x86_64: vfio-pci: Cannot read device rom at 0000:01:00.0
Device option ROM contents are probably invalid (check dmesg).
Skip option ROM probe with rombar=0, or load from file with romfile=".
Until I reboot the host.

Start script:

vfio-bind 0000:01:00.0 0000:01:00.1

qemu-system-x86_64 -enable-kvm -m 1024 -cpu host,kvm=off \

-smp 4,sockets=1,cores=4,threads=1 \

-device vfio-pci,host=01:00.0,x-vga=on -device vfio-pci,host=01:00.1 \

-vga none



vfio-bind:

#!/bin/bash

modprobe vfio-pci

for dev in "$@"; do

vendor=$(cat /sys/bus/pci/devices/$dev/vendor)

device=$(cat /sys/bus/pci/devices/$dev/device)

if [ -e /sys/bus/pci/devices/$dev/driver ]; then

echo $dev > /sys/bus/pci/devices/$dev/driver/unbind

fi

echo $vendor $device > /sys/bus/pci/drivers/vfio-pci/new_id

done


Is there a fix for this problem?




More information about the vfio-users mailing list