ci: Make sure that the Crosvm control socket has been removed

To avoid Crosvm bailing out at startup like this:

ERROR - dEQP error: [ERROR:src/main.rs:2826] invalid value "crosvm-14.sock": this socket path already exists

Closes: #7093

Reviewed-by: David Heidelberg <david.heidelberg@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18414>
This commit is contained in:
Tomeu Vizoso
2022-09-05 11:01:00 +02:00
parent a6050a43ca
commit 0a2723e35d

View File

@@ -55,8 +55,12 @@ VM_SOCKET=crosvm-${THREAD}.sock
# without cleaning itself up.
if [ -e $VM_SOCKET ]; then
crosvm stop $VM_SOCKET || rm -rf $VM_SOCKET
# Wait for Crosvm to have removed the socket
until [ ! -f $VM_SOCKET ]; do
sleep 1
done
# Wait for socats from that invocation to drain
sleep 5
sleep 4
fi
set_vsock_context || { echo "Could not generate crosvm vsock CID" >&2; exit 1; }