qemu passthrough parou de funcionar

1

Eu tenho trabalhado na configuração de um Windows vm com gpu Passthrough no Ubuntu 17.10 até o qemu nos últimos dias. O mais distante que consegui foi executar um script muito semelhante a este:

#!/bin/bash

vmname="betterwin10vm"

if ps -A | grep -q $vmname; then
echo "$vmname is already running." &
exit 1

else

# use pulseaudio
export QEMU_AUDIO_DRV=pa
export QEMU_PA_SAMPLES=8192
export QEMU_AUDIO_TIMER_PERIOD=99
export QEMU_PA_SERVER=/run/user/1000/pulse/native

cp /usr/share/OVMF/OVMF_VARS.fd /tmp/my_vars.fd

qemu-system-x86_64 \
-name $vmname,process=$vmname \
-machine type=pc,accel=kvm \
-cpu host \
-smp 3,sockets=1,cores=3,threads=1 \
-m size=4G \
-mem-path /dev/hugepages \
-mem-prealloc \
-balloon none \
-rtc clock=host,base=localtime \
-vga none \
-nographic \
-serial none \
-parallel none \
-soundhw hda \
-usb -usbdevice host:1532:0214 -usbdevice host:1532:0043 \
-device vfio-pci,host=04:00.0,multifunction=on \
-device vfio-pci,host=04:00.1 \
-drive if=pflash,format=raw,readonly,file=/usr/share/OVMF/OVMF_CODE.fd \
-drive if=pflash,format=raw,file=/tmp/my_vars.fd \
-boot order=dc \
-drive if=virtio,id=disk0,cache=none,format=raw,file=/dev/sdb1 \
-drive file=/home/keith/Downloads/lubuntu-17.10.1-desktop-amd64.iso,index=1,media=cdrom \
-drive file=/home/keith/WIN_VM/virtio-win-0.1.141-2.iso,index=2,media=cdrom \

exit 0
fi

que ontem me permitiu executar o lubuntu e depois instalar o windows10 (até que ele não pudesse instalar meus drivers virtio) na VM que estou planejando usar para windows. Hoje, não consigo nem inicializar o iso, nem posso exibir até mesmo o BIOS no meu monitor secundário conectado à GPU (04: 00.0). A única maneira de ver que nada está sendo inicializado é quando desativo a propriedade -vga none e permito que o qemu seja executado em janelas. Meu mouse e teclado também são conectados à VM, então eu sei que ela está ligada. Embora eu não tenha nenhuma explicação de por que minha iso não está inicializando, quando executo dmesg | grep vfio , recebo essa resposta (encurtada) repetida várias vezes.

[    2.303445] vfio-pci 0000:04:00.0: vgaarb: changed VGA decodes: olddecodes=io+mem,decodes=io+mem:owns=none
[    2.320128] vfio_pci: add [1002:67df[ffff:ffff]] class 0x000000/00000000
[    2.344187] vfio_pci: add [1002:aaf0[ffff:ffff]] class 0x000000/00000000
[ 2805.815146] vfio-pci 0000:04:00.0: Refused to change power state, currently in D3
[ 2805.835195] vfio-pci 0000:04:00.0: Refused to change power state, currently in D3
[ 2805.855139] vfio-pci 0000:04:00.0: Refused to change power state, currently in D3
[ 2806.583096] vfio-pci 0000:04:00.0: timed out waiting for pending transaction; performing function level reset anyway
[ 2807.771124] vfio-pci 0000:04:00.0: Failed to return from FLR
[ 2807.773191] vfio_cap_init: 0000:04:00.0 hiding cap 0xff
[ 2807.773194] vfio_cap_init: 0000:04:00.0 hiding cap 0xff
[ 2807.773198] vfio_cap_init: 0000:04:00.0 hiding cap 0xff
[ 2807.773201] vfio_cap_init: 0000:04:00.0 hiding cap 0xff
[ 2807.773336] vfio_cap_init: 0000:04:00.0 hiding cap 0xff
[ 2807.773339] vfio_cap_init: 0000:04:00.0 hiding cap 0xff
[ 2807.795138] vfio-pci 0000:04:00.1: Refused to change power state, currently in D3
[ 2807.815138] vfio-pci 0000:04:00.1: Refused to change power state, currently in D3
[ 2807.835154] vfio-pci 0000:04:00.1: Refused to change power state, currently in D3
[ 2808.567093] vfio-pci 0000:04:00.1: timed out waiting for pending transaction; performing function level reset anyway
[ 2809.755122] vfio-pci 0000:04:00.1: Failed to return from FLR
[ 2809.757190] vfio_cap_init: 0000:04:00.1 hiding cap 0xff
[ 2809.757194] vfio_cap_init: 0000:04:00.1 hiding cap 0xff
[ 2809.757197] vfio_cap_init: 0000:04:00.1 hiding cap 0xff
[ 2809.757200] vfio_cap_init: 0000:04:00.1 hiding cap 0xff
[ 2809.757204] vfio_cap_init: 0000:04:00.1 hiding cap 0xff
[ 2809.757207] vfio_cap_init: 0000:04:00.1 hiding cap 0xff
[ 2809.757331] vfio_cap_init: 0000:04:00.1 hiding cap 0xff
[ 2809.757334] vfio_cap_init: 0000:04:00.1 hiding cap 0xff
[ 2809.757337] vfio_cap_init: 0000:04:00.1 hiding cap 0xff
[ 2809.831139] vfio-pci 0000:04:00.1: Refused to change power state, currently in D3
[ 2810.583131] vfio-pci 0000:04:00.1: timed out waiting for pending transaction; performing function level reset anyway
[ 2811.771126] vfio-pci 0000:04:00.1: Failed to return from FLR
[ 2811.791130] vfio-pci 0000:04:00.0: Refused to change power state, currently in D3
[ 2812.535123] vfio-pci 0000:04:00.0: timed out waiting for pending transaction; performing function level reset anyway
[ 2813.723127] vfio-pci 0000:04:00.0: Failed to return from FLR
[ 2945.935092] vfio-pci 0000:04:00.1: Refused to change power state, currently in D3
[ 2946.679158] vfio-pci 0000:04:00.1: timed out waiting for pending transaction; performing function level reset anyway
[ 2947.867152] vfio-pci 0000:04:00.1: Failed to return from FLR
[ 2947.887159] vfio-pci 0000:04:00.0: Refused to change power state, currently in D3
[ 2948.631161] vfio-pci 0000:04:00.0: timed out waiting for pending transaction; performing function level reset anyway
[ 2949.819151] vfio-pci 0000:04:00.0: Failed to return from FLR
[ 3692.523889] vfio-pci 0000:04:00.0: Refused to change power state, currently in D3
[ 3692.543829] vfio-pci 0000:04:00.0: Refused to change power state, currently in D3
[ 3692.563836] vfio-pci 0000:04:00.0: Refused to change power state, currently in D3
[ 3693.307807] vfio-pci 0000:04:00.0: timed out waiting for pending transaction; performing function level reset anyway
[ 3694.495843] vfio-pci 0000:04:00.0: Failed to return from FLR

Isso poderia ter algo a ver com meus problemas? Se sim, como devo lidar com isso? Obrigado :)

    
por a rad white lad 22.02.2018 / 02:16

0 respostas