Skip to content
Commit 2570ee28 authored by Kenneth Graunke's avatar Kenneth Graunke Committed by Juan A. Suarez Romero
Browse files

egl: Only expose 565 pbuffer configs if X can export them as DRI3 images



Glamor in xorg-server 1.20 cannot expose 16bpp pixmaps when running in
the usual 24bpp mode.  This meant our 565 pbuffer configs would
ultimately fail to create a backing pixmap, leading to crashes.

To hack around this, make a 16bpp pixmap and try and export it.
If it works, expose the configs.  Otherwise, just skip them.

This also disables them on DRI2.  These configs were only added to pass
conformance requirements, and I doubt anybody cares about testing out
565 pbuffer visuals on DRI2-only drivers.

v2: Don't leak the fds (caught by Eric Anholt)
v3: Don't free(fds), it's not malloc'd

Fixes: dacb11a5 ("egl: Add a 565 pbuffer-only EGL config under X11.")
Reviewed-by: default avatarEric Anholt <eric@anholt.net>
(cherry picked from commit 82607f8a)
parent f8c0b90f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment