panfrost: Crash when trying to use EGL_KHR_partial_update
I've been trying to implement EGL_KHR_partial_update
on kwin_wayland using eglSetDamageRegionKHR
and I've been getting consistently a crash when calling eglSetDamageRegionKHR(). In fact eglGetProcAddress("eglSetDamageRegionKHR")
is returning NULL to me.
Since I assumed I was doing something wrong, I checked on weston and there it seems to have the same problem. See below. Could anyone help me see what's going wrong there?
[17:06:00.350] weston 8.0.90
https://wayland.freedesktop.org
Bug reports to: https://gitlab.freedesktop.org/wayland/weston/issues/
Build: 8.0.0-89-g8060d826+
[17:06:00.350] Command line: /home/apol/weston/build/compositor/weston
[17:06:00.350] OS: Linux, 5.5.0-3.1-MANJARO-ARM, #1 SMP Mon Feb 10 20:59:01 +03 2020, aarch64
[17:06:00.350] Starting with no config file.
[17:06:00.350] Output repaint window is 7 ms maximum.
[17:06:00.350] Loading module '/home/apol/prefix/mesa/lib/libweston-9/drm-backend.so'
[17:06:00.407] initializing drm backend
[17:06:00.419] logind: session control granted
[17:06:00.426] using /dev/dri/card0
[17:06:00.426] DRM: supports universal planes
[17:06:00.426] DRM: supports atomic modesetting
[17:06:00.426] DRM: supports picture aspect ratio
[17:06:00.427] Loading module '/home/apol/prefix/mesa/lib/libweston-9/gl-renderer.so'
[17:06:01.402] EGL client extensions: EGL_EXT_device_base
EGL_EXT_device_enumeration EGL_EXT_device_query
EGL_EXT_platform_base EGL_KHR_client_get_all_proc_addresses
EGL_EXT_client_extensions EGL_KHR_debug
EGL_EXT_platform_wayland EGL_EXT_platform_x11
EGL_MESA_platform_gbm EGL_MESA_platform_surfaceless
EGL_EXT_platform_device
[17:06:01.404] EGL version: 1.4
[17:06:01.404] EGL vendor: Mesa Project
[17:06:01.404] EGL client APIs: OpenGL OpenGL_ES
[17:06:01.404] EGL extensions: EGL_ANDROID_blob_cache EGL_EXT_buffer_age
EGL_EXT_image_dma_buf_import EGL_KHR_cl_event2
EGL_KHR_config_attribs EGL_KHR_create_context
EGL_KHR_create_context_no_error EGL_KHR_fence_sync
EGL_KHR_get_all_proc_addresses EGL_KHR_gl_colorspace
EGL_KHR_gl_renderbuffer_image EGL_KHR_gl_texture_2D_image
EGL_KHR_gl_texture_3D_image EGL_KHR_gl_texture_cubemap_image
EGL_KHR_image EGL_KHR_image_base EGL_KHR_image_pixmap
EGL_KHR_no_config_context EGL_KHR_partial_update
EGL_KHR_reusable_sync EGL_KHR_surfaceless_context
EGL_EXT_pixel_format_float EGL_KHR_wait_sync
EGL_MESA_configless_context EGL_MESA_drm_image
EGL_MESA_image_dma_buf_export EGL_MESA_query_driver
EGL_WL_bind_wayland_display
weston: ../libweston/renderer-gl/egl-glue.c:631: gl_renderer_setup_egl_extensions: Assertion `gr->set_damage_region' failed.
Program received signal SIGABRT, Aborted.
0x0000fffff7e40ab8 in raise () from /usr/lib/libc.so.6
(gdb) where
#0 0x0000fffff7e40ab8 in raise () at /usr/lib/libc.so.6
#1 0x0000fffff7e2dce8 in abort () at /usr/lib/libc.so.6
#2 0x0000fffff7e3a254 in __assert_fail_base () at /usr/lib/libc.so.6
#3 0x0000fffff7e3a2bc in () at /usr/lib/libc.so.6
#4 0x0000fffff7f835ac in gl_renderer_setup_egl_extensions (ec=0xaaaaaaaca6d0) at ../libweston/renderer-gl/egl-glue.c:631
#5 0x0000fffff7f8b65c in gl_renderer_display_create (ec=0xaaaaaaaca6d0, platform=12759, native_display=0xaaaaaaae5ff0, egl_surface_type=4, drm_formats=0xfffffffff228, drm_formats_count=3)
at ../libweston/renderer-gl/gl-renderer.c:3411
#6 0x0000fffff72fc790 in drm_backend_create_gl_renderer (b=0xaaaaaaad1210) at ../libweston/backend-drm/drm-gbm.c:105
#7 0x0000fffff72fc818 in init_egl (b=0xaaaaaaad1210) at ../libweston/backend-drm/drm-gbm.c:125
#8 0x0000fffff72f2134 in drm_backend_create (compositor=0xaaaaaaaca6d0, config=0xfffffffff2e0) at ../libweston/backend-drm/drm.c:2876
#9 0x0000fffff72f266c in weston_backend_init (compositor=0xaaaaaaaca6d0, config_base=0xfffffffff3c0) at ../libweston/backend-drm/drm.c:3034
#10 0x0000fffff7dc936c in weston_compositor_load_backend (compositor=0xaaaaaaaca6d0, backend=WESTON_BACKEND_DRM, config_base=0xfffffffff3c0) at ../libweston/compositor.c:7814
#11 0x0000fffff7fae638 in load_drm_backend (c=0xaaaaaaaca6d0, argc=0xfffffffff50c, argv=0xfffffffffa48, wc=0x0) at ../compositor/main.c:2518
#12 0x0000fffff7faf990 in load_backend (compositor=0xaaaaaaaca6d0, backend=0xaaaaaaaca400 "drm-backend.so", argc=0xfffffffff50c, argv=0xfffffffffa48, config=0x0) at ../compositor/main.c:2995
#13 0x0000fffff7fb042c in wet_main (argc=1, argv=0xfffffffffa48) at ../compositor/main.c:3271
#14 0x0000aaaaaaaaa7a8 in main (argc=1, argv=0xfffffffffa48) at ../compositor/executable.c:33
Edited by Aleix Pol