mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-27 01:50:10 +01:00
EGL: legacy-x11=dri2 should support hardware driver
Since MR !33891 EGL only supports a software driver (LLVM).
Routine dri3_x11_connect at
src/egl/drivers/dri2/platform_x11.c fails if DRI3 is not
available. So at that location variable *allow_dri2 should be set.
Looking at the major codition, we see it is not executed
if LIBGL_DRI3_DISABLE is set. In that case the hardware driver
is activated as desired. Previously this was not needed.
Also it is not practical, and not necessary.
I do not understand the major condition, so I did not change it.
This causes some duplicate coding.
Fixes: 323bad6b18 ("egl/x11: split out dri2 init entirely")
Signed-off-by: GKraats <vd.kraats@hccnet.nl>
Acked-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/34530>
This commit is contained in:
parent
76031ba53d
commit
995dc61bf5
1 changed files with 9 additions and 2 deletions
|
|
@ -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))
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue