On 6/27/22 16:10, Marc-André Lureau wrote:
> Could you describe how to reproduce? I naively --disable-virglrenderer and I get:
>
> $ tests/venv/bin/avocado run tests/avocado/virtio-gpu.py
> Fetching asset from tests/avocado/virtio-gpu.py:VirtioGPUx86.test_virtio_vga_virgl
> Fetching asset from tests/avocado/virtio-gpu.py:VirtioGPUx86.test_virtio_vga_virgl
> Fetching asset from tests/avocado/virtio-gpu.py:VirtioGPUx86.test_vhost_user_vga_virgl
> Fetching asset from tests/avocado/virtio-gpu.py:VirtioGPUx86.test_vhost_user_vga_virgl
> JOB ID : d9c5b65777777564d1d926fdfb58deaf0e967d15
> JOB LOG : /home/elmarco/avocado/job-results/job-2022-06-27T12.56-d9c5b65/job.log
> (1/2) tests/avocado/virtio-gpu.py:VirtioGPUx86.test_virtio_vga_virgl: CANCEL: VirGL not
> enabled? (0.08 s)
> (2/2) tests/avocado/virtio-gpu.py:VirtioGPUx86.test_vhost_user_vga_virgl: CANCEL: Could
> not find vhost-user-gpu (0.02 s)
> RESULTS : PASS 0 | ERROR 0 | FAIL 0 | SKIP 0 | WARN 0 | INTERRUPT 0 | CANCEL 2
> JOB TIME : 0.56 s
Ah, I beg your pardon -- virglrenderer is *not* disabled, I merely assumed it was. But
the effect is still there -- dead qemu not reaped, indefinite hang on the driver.
The end of the log is:
> 2022-06-27 17:32:19,746 stacktrace L0045 ERROR| Command: ./qemu-system-x86_64 -display none -vga none -chardev socket,id=mon,path=/var/tmp/avo_qemu_sock_4j1r4bdf/qemu-245052-7f2a8c8a3bb0-monitor.sock -mon chardev=mon,mode=control -chardev socket,id=console,path=/var/tmp/avo_qemu_sock_4j1r4bdf/qemu-245052-7f2a8c8a3bb0-console.sock,server=on,wait=off -serial chardev:console -cpu host -m 2G -machine pc,accel=kvm -device virtio-vga-gl -display egl-headless -kernel /home/rth/avocado/data/cache/by_location/892ae21f3ae7d04994d81e1c0bf204ecebe555bb/vmlinuz -initrd /home/rth/avocado/data/cache/by_location/892ae21f3ae7d04994d81e1c0bf204ecebe555bb/initrd.img -append printk.time=0 console=ttyS0 rdinit=/bin/bash
> 2022-06-27 17:32:19,746 stacktrace L0045 ERROR| Output: qemu-system-x86_64: -display egl-headless: Parameter 'type' does not accept value 'egl-headless'
if that helps.
Ok I managed to reproduce, it's enough to give invalid arguments to make it hang for a long while.
This a flaw in machine.py, which waits for the qemu QMP connection, forever. We could first teach it to wait for the default 15s max.
But machine.py probably needs to be ported to the async QMPClient (python/qemu/qmp/legacy.py).
For now, I'll send a simpler fix and leave TODOs for later ;)