mesa/src/egl/drivers/dri2
Leandro Ribeiro 88c03ddd34 egl/drm: get compatible render-only device fd for kms-only device
Things have been working by accident for split display/render SoCs when
using the GBM platform.

The device fd given to the GBM platform may be associated with a
KMS-only device, so _eglFindDevice() should find nothing (because the
global EGLDevice list only has render-capable devices). The only thing
making it work is that we don't error out when we go through the
EGLDevice list and can't find the device we are looking for. We simply
return the last EGLDevice from the list.

This patch fixes that. Now we look for a compatible render-only device
for the KMS-only in the GBM platform.

Signed-off-by: Leandro Ribeiro <leandro.ribeiro@collabora.com>
Reviewed-by: Simon Ser <contact@emersion.fr>
Reviewed-by: Daniel Stone <daniels@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24825>
2023-10-17 20:31:13 +00:00
..
egl_dri2.c egl: Advertise EGL_MESA_gl_interop extension if support present 2023-08-19 01:08:30 +00:00
egl_dri2.h egl: move is_render_node flag to platform_wayland 2023-10-04 17:01:42 +00:00
platform_android.c egl: android: Remove legacy name-based shared buffers support 2023-07-28 17:09:14 +00:00
platform_android.h egl: re-format using clang-format 2023-07-07 23:00:06 +00:00
platform_android_mapper.cpp egl: re-format using clang-format 2023-07-07 23:00:06 +00:00
platform_device.c egl: Rename _eglAddDevice() to _eglFindDevice() 2023-07-17 22:27:01 +00:00
platform_drm.c egl/drm: get compatible render-only device fd for kms-only device 2023-10-17 20:31:13 +00:00
platform_surfaceless.c egl: don't set ForceSoftware for all zink loading 2023-10-09 18:43:09 +00:00
platform_wayland.c egl: don't set ForceSoftware for all zink loading 2023-10-09 18:43:09 +00:00
platform_x11.c egl: don't set ForceSoftware for all zink loading 2023-10-09 18:43:09 +00:00
platform_x11.h egl/x11: implement ANGLE_sync_control_rate 2022-08-09 21:02:50 +00:00
platform_x11_dri3.c egl/dri3: only set driver_name if not already set 2023-08-31 17:54:26 +00:00
platform_x11_dri3.h egl/x11: Split declaration of dri2_format_for_depth into header platform_x11.h 2022-08-09 21:02:50 +00:00