Mesa (master): egl: Improve the debugging of gbm format matching in DRI configs.

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Mon Nov 12 23:28:57 UTC 2018


Module: Mesa
Branch: master
Commit: 621b0fa8922ade0a8122b868177308e65e6d3595
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=621b0fa8922ade0a8122b868177308e65e6d3595

Author: Eric Anholt <eric at anholt.net>
Date:   Mon Oct 29 09:28:00 2018 -0700

egl: Improve the debugging of gbm format matching in DRI configs.

Previously the debug would be:

libEGL debug: No DRI config supports native format 0x20203852
libEGL debug: No DRI config supports native format 0x38385247

but

libEGL debug: No DRI config supports native format R8
libEGL debug: No DRI config supports native format GR88

is a lot easier to understand.

Reviewed-by: Eric Engestrom <eric.engestrom at intel.com>
Reviewed-by: Daniel Stone <daniels at collabora.com>

---

 src/egl/drivers/dri2/platform_drm.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/egl/drivers/dri2/platform_drm.c b/src/egl/drivers/dri2/platform_drm.c
index 68ec8322e9..fb346e0073 100644
--- a/src/egl/drivers/dri2/platform_drm.c
+++ b/src/egl/drivers/dri2/platform_drm.c
@@ -664,8 +664,9 @@ drm_add_configs_for_visuals(_EGLDriver *drv, _EGLDisplay *disp)
 
    for (unsigned i = 0; i < ARRAY_SIZE(format_count); i++) {
       if (!format_count[i]) {
-         _eglLog(_EGL_DEBUG, "No DRI config supports native format 0x%x",
-                 visuals[i].gbm_format);
+         struct gbm_format_name_desc desc;
+         _eglLog(_EGL_DEBUG, "No DRI config supports native format %s",
+                 gbm_format_get_name(visuals[i].gbm_format, &desc));
       }
    }
 




More information about the mesa-commit mailing list