ci: when specifying a driver remove all other ones

If we need to specify a driver, it means several drivers could pick up this gpu;
ensure that the other driver can't accidentally be used.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/25434>
This commit is contained in:
Eric Engestrom
2023-09-27 13:37:25 +01:00
committed by Marge Bot
parent a53af34664
commit 90b6f84c5e

View File

@@ -7,6 +7,8 @@
# Second-stage init, used to set up devices and our job environment before
# running tests.
shopt -s extglob
# Make sure to kill itself and all the children process from this script on
# exiting, since any console output may interfere with LAVA signals handling,
# which based on the log console.
@@ -106,6 +108,13 @@ export XDG_CACHE_HOME=/tmp
# Make sure Python can find all our imports
export PYTHONPATH=$(python3 -c "import sys;print(\":\".join(sys.path))")
# If we need to specify a driver, it means several drivers could pick up this gpu;
# ensure that the other driver can't accidentally be used
if [ -n "$MESA_LOADER_DRIVER_OVERRIDE" ]; then
rm /install/lib/dri/!($MESA_LOADER_DRIVER_OVERRIDE)_dri.so
fi
ls -l /install/lib/dri/*_dri.so
if [ "$HWCI_FREQ_MAX" = "true" ]; then
# Ensure initialization of the DRM device (needed by MSM)
head -0 /dev/dri/renderD128