From 81cea66ff1c4d7c2c5167715ff9968754a58bfd1 Mon Sep 17 00:00:00 2001 From: Eric Engestrom Date: Wed, 20 Dec 2017 15:53:09 +0000 Subject: [PATCH] egl: rename LIBGL_ALWAYS_SOFTWARE variable from UseFallback to ForceSoftware Signed-off-by: Eric Engestrom Reviewed-by: Emil Velikov --- src/egl/drivers/dri2/platform_android.c | 2 +- src/egl/drivers/dri2/platform_drm.c | 2 +- src/egl/drivers/dri2/platform_surfaceless.c | 2 +- src/egl/drivers/dri2/platform_wayland.c | 2 +- src/egl/drivers/dri2/platform_x11.c | 2 +- src/egl/main/egldisplay.h | 2 +- src/egl/main/egldriver.c | 4 ++-- 7 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/egl/drivers/dri2/platform_android.c b/src/egl/drivers/dri2/platform_android.c index 1b3092b7b3b..34e3ef66bfe 100644 --- a/src/egl/drivers/dri2/platform_android.c +++ b/src/egl/drivers/dri2/platform_android.c @@ -1180,7 +1180,7 @@ dri2_initialize_android(_EGLDriver *drv, _EGLDisplay *dpy) int ret; /* Not supported yet */ - if (disp->Options.UseFallback) + if (disp->Options.ForceSoftware) return EGL_FALSE; loader_set_logger(_eglLog); diff --git a/src/egl/drivers/dri2/platform_drm.c b/src/egl/drivers/dri2/platform_drm.c index a2d18ef5089..6e7403d9ab2 100644 --- a/src/egl/drivers/dri2/platform_drm.c +++ b/src/egl/drivers/dri2/platform_drm.c @@ -653,7 +653,7 @@ dri2_initialize_drm(_EGLDriver *drv, _EGLDisplay *disp) const char *err; /* Not supported yet */ - if (disp->Options.UseFallback) + if (disp->Options.ForceSoftware) return EGL_FALSE; loader_set_logger(_eglLog); diff --git a/src/egl/drivers/dri2/platform_surfaceless.c b/src/egl/drivers/dri2/platform_surfaceless.c index 977b0460166..70b302c0ce4 100644 --- a/src/egl/drivers/dri2/platform_surfaceless.c +++ b/src/egl/drivers/dri2/platform_surfaceless.c @@ -324,7 +324,7 @@ dri2_initialize_surfaceless(_EGLDriver *drv, _EGLDisplay *disp) dri2_dpy->fd = -1; disp->DriverData = (void *) dri2_dpy; - if (!disp->Options.UseFallback) { + if (!disp->Options.ForceSoftware) { driver_loaded = surfaceless_probe_device(disp, false); if (!driver_loaded) _eglLog(_EGL_WARNING, diff --git a/src/egl/drivers/dri2/platform_wayland.c b/src/egl/drivers/dri2/platform_wayland.c index 02b32f98885..05a347abfce 100644 --- a/src/egl/drivers/dri2/platform_wayland.c +++ b/src/egl/drivers/dri2/platform_wayland.c @@ -1999,7 +1999,7 @@ dri2_initialize_wayland(_EGLDriver *drv, _EGLDisplay *disp) { EGLBoolean initialized = EGL_FALSE; - if (!disp->Options.UseFallback) + if (!disp->Options.ForceSoftware) initialized = dri2_initialize_wayland_drm(drv, disp); if (!initialized) diff --git a/src/egl/drivers/dri2/platform_x11.c b/src/egl/drivers/dri2/platform_x11.c index 8ede590bfab..78a51ba0e53 100644 --- a/src/egl/drivers/dri2/platform_x11.c +++ b/src/egl/drivers/dri2/platform_x11.c @@ -1459,7 +1459,7 @@ dri2_initialize_x11(_EGLDriver *drv, _EGLDisplay *disp) { EGLBoolean initialized = EGL_FALSE; - if (!disp->Options.UseFallback) { + if (!disp->Options.ForceSoftware) { #ifdef HAVE_DRI3 if (!env_var_as_boolean("LIBGL_DRI3_DISABLE", false)) initialized = dri2_initialize_x11_dri3(drv, disp); diff --git a/src/egl/main/egldisplay.h b/src/egl/main/egldisplay.h index 0005c81836d..addf430ffed 100644 --- a/src/egl/main/egldisplay.h +++ b/src/egl/main/egldisplay.h @@ -160,7 +160,7 @@ struct _egl_display /* options that affect how the driver initializes the display */ struct { - EGLBoolean UseFallback; /**< Use fallback driver (sw or less features) */ + EGLBoolean ForceSoftware; /**< Use software path only */ void *Platform; /**< Platform-specific options */ } Options; diff --git a/src/egl/main/egldriver.c b/src/egl/main/egldriver.c index 34a90ae5dc5..ee3dc86e388 100644 --- a/src/egl/main/egldriver.c +++ b/src/egl/main/egldriver.c @@ -84,12 +84,12 @@ _eglMatchDriver(_EGLDisplay *dpy) assert(!dpy->Initialized); /* set options */ - dpy->Options.UseFallback = + dpy->Options.ForceSoftware = env_var_as_boolean("LIBGL_ALWAYS_SOFTWARE", false); best_drv = _eglMatchAndInitialize(dpy); if (!best_drv) { - dpy->Options.UseFallback = EGL_TRUE; + dpy->Options.ForceSoftware = EGL_TRUE; best_drv = _eglMatchAndInitialize(dpy); } -- 2.30.2