@@ -65,11 +65,16 @@ jobs:
6565
6666 - name : kvm actually executes guest code
6767 run : |
68+ set +e
6869 k=$(ls /boot/vmlinuz-* 2>/dev/null | head -1)
70+ echo "kernel image: ${k:-none found}"
6971 if [ -z "$k" ]; then echo "PROBE: no kernel on runner, skipped"; exit 0; fi
72+ # Runner kernels are commonly mode 600, so read it as root.
73+ sudo cp "$k" /tmp/vmlinuz && sudo chmod a+r /tmp/vmlinuz
7074 timeout 90 qemu-system-x86_64 -accel kvm -cpu host -smp 2 -m 1024 \
7175 -display none -serial stdio -no-reboot \
72- -kernel "$k" -append "console=ttyS0 panic=-1" 2>&1 | head -40 | tee out
76+ -kernel /tmp/vmlinuz -append "console=ttyS0 panic=-1" > out 2>&1
77+ head -25 out
7378 grep -q 'Linux version' out \
7479 && echo "PROBE: guest kernel BOOTED under kvm" \
7580 || echo "PROBE: guest did not boot"
8893 [ $rc -eq 0 ] && echo "PROBE: virtio-vga-gl + egl-headless ok" \
8994 || echo "PROBE: virtio-vga-gl + egl-headless FAILED rc=$rc"
9095
96+ # egl-headless wants a DRM render node and a hosted runner has no GPU.
97+ # smoke.sh already takes the display as $QEMU_DISPLAY, so the question
98+ # is which alternative gives the guest a DRM device to run a
99+ # compositor on. Software rendering in the guest is fine; what is not
100+ # fine is a guest with no GPU device at all.
101+ - name : display modes without a host GPU
102+ run : |
103+ set +e
104+ ls -l /dev/dri 2>/dev/null || echo "no /dev/dri on the host"
105+ sudo modprobe vgem 2>/dev/null && ls -l /dev/dri 2>/dev/null
106+ for combo in "-device virtio-vga -display none" \
107+ "-device virtio-gpu-pci -display none" \
108+ "-vga std -display none" \
109+ "-device virtio-vga-gl -display egl-headless"; do
110+ timeout 30 qemu-system-x86_64 -enable-kvm -cpu host -m 512 \
111+ $combo -S -monitor stdio <<< 'quit' > out 2>&1
112+ rc=$?
113+ [ $rc -eq 0 ] && echo "PROBE: ok $combo" \
114+ || echo "PROBE: FAILED $combo ($(head -1 out))"
115+ done
116+
91117 - name : loop devices and partition scanning
92118 run : |
93119 set +e
0 commit comments