From a9bf70486d987091d7435b448dddb4be3e346f6b Mon Sep 17 00:00:00 2001 From: Eric Engestrom Date: Sun, 8 Feb 2026 19:06:52 +0100 Subject: [PATCH] pvr/drm-shim: avoid trying a random bvnc by default If `PVR_SHIM_DEVICE_BVNC` is not set, we would try the bvnc corresponding to whatever was in uninitialised memory, which would likely fail, and then fallback to `DEFAULT_DEVICE_BVNC`. Instead, initialize to `DEFAULT_DEVICE_BVNC` so that "unset bvnc" and "invalid bvnc" behave the same. Fixes: ba104d3e923aeb14e4fa ("pvr: add support for drm-shim") Reviewed-by: Simon Perretta Part-of: --- src/imagination/drm-shim/pvr_noop.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/imagination/drm-shim/pvr_noop.c b/src/imagination/drm-shim/pvr_noop.c index 5ce3ec6ef05..fd0338de380 100644 --- a/src/imagination/drm-shim/pvr_noop.c +++ b/src/imagination/drm-shim/pvr_noop.c @@ -488,7 +488,7 @@ static void init_overrides(void) const char *device_bvnc = debug_get_option("PVR_SHIM_DEVICE_BVNC", NULL); static const char *delims = ",;"; unsigned b, v, n, c; - uint64_t bvnc; + uint64_t bvnc = DEFAULT_DEVICE_BVNC; int ret; if (device_bvnc) {