diff --git a/.pick_status.json b/.pick_status.json index 2086dea8a5c..4b083a54267 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -1024,7 +1024,7 @@ "description": "EGL: legacy-x11=dri2 should support hardware driver", "nominated": true, "nomination_type": 2, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": "323bad6b18717fcc395f67ef508e5a3d0aed7d02", "notes": null diff --git a/src/egl/drivers/dri2/platform_x11.c b/src/egl/drivers/dri2/platform_x11.c index 48f14f29938..14335e0b504 100644 --- a/src/egl/drivers/dri2/platform_x11.c +++ b/src/egl/drivers/dri2/platform_x11.c @@ -1989,8 +1989,15 @@ dri2_initialize_x11(_EGLDisplay *disp, bool *allow_dri2) /* the status here is ignored for zink-with-kopper and swrast, * otherwise return whatever error/fallback status as failure */ - if (!dri2_dpy->kopper && !disp->Options.ForceSoftware && !status) - return EGL_FALSE; + if (!dri2_dpy->kopper && !disp->Options.ForceSoftware) { +#ifdef HAVE_X11_DRI2 + *allow_dri2 = !debug_get_bool_option("LIBGL_DRI2_DISABLE", false); +#else + *allow_dri2 = false; +#endif + if (!status) + return EGL_FALSE; + } } #endif if (!dri2_load_driver(disp))