Skip to content

egl: return correct error for EGL_KHR_image_pixmap

Eric Engestrom requested to merge eric/mesa:eglCreateImage-no-context into main

EGL_KHR_image_pixmap says:

If is EGL_NATIVE_PIXMAP_KHR, and is not EGL_NO_CONTEXT, the error EGL_BAD_PARAMETER is generated.

Reported-by: @shadeslayer
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=109354
Fixes: a1c4a8a3 "egl: Add support for EGL_KHR_image."


This is a complicated bug, because xorg-server has been relying on it since 1.16.0, and the fix (see MR xorg/xserver!95 (merged)) has not even landed in any release yet.

I'm sending this MR out so that we have a fix ready for merging (and so that we don't forget), but marking it as WIP so that is doesn't get merged for now.

@ajax @anholt: I'll let you guys decide when you think Xserver's been fixed for long enough for the fix to land in Mesa 😉

Merge request reports