egl: add EGL_EXT_device_drm support

Graphics / Mesa 3D Graphics Library / Mesa - Emil Velikov [] - 1 November 2018 00:05 UTC

Add implementation based around the drmDevice API. As such it's only available only when building with libdrm. With the latter already a requirement when using !SW code paths in the platform code.

Note: the current code will work if a device is hot-plugged. Yet hot-unplugged is not implemented, since I have no ways of testing it.

v2:- ddd some _eglDeviceSupports checks- require DRM_NODE_RENDER- add _eglGetDRMDeviceRenderNode helper

v3:- flip inverted asserts (Mathias)

dbb4457d98 egl: add EGL_EXT_device_drm support
src/egl/main/egldevice.c | 113 +++++++++++++++++++++++++++++++++++++++++++++++
src/egl/main/egldevice.h | 4 ++
2 files changed, 117 insertions(+)


  • Share