Mesa fails to support multiple EGLDisplays from a single driver
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mir |
Fix Released
|
Medium
|
Robert Carr |
Bug Description
First, allow me to clarify some of the abstractions in mesa-egl as I found the terminology a little confusing.
On one hand, EGL has platforms (PLATFORM_WAYLAND, PLATFORM_X11, PLATFORM_MIR), on the other hand there is a mesa internal notion of an "EGL driver" i.e. dri2, glx.
Currently it is possible to construct one EGLDisplay per driver even with seperate platforms, however to support some of the use cases in https:/
we will need to support multiple EGL displays from a single driver (dri2) with seperate platforms.
i.e. running outside a system compositor, mir itself will need EGLDisplay(
Related branches
- Chris Halse Rogers: Approve
- Kevin DuBois (community): Approve
- PS Jenkins bot (community): Approve (continuous-integration)
- Alexandros Frantzis (community): Needs Fixing
- Alan Griffiths: Abstain
-
Diff: 1506 lines (+879/-66)48 files modifiedexamples/CMakeLists.txt (+4/-0)
examples/demo-inprocess-egl/CMakeLists.txt (+11/-0)
examples/demo-inprocess-egl/demo_inprocess_egl.cpp (+48/-0)
examples/demo-inprocess-egl/example_egl_helper.cpp (+78/-0)
examples/demo-inprocess-egl/example_egl_helper.h (+53/-0)
examples/demo-inprocess-egl/inprocess_egl_client.cpp (+83/-0)
examples/demo-inprocess-egl/inprocess_egl_client.h (+61/-0)
include/client/mir_toolkit/mir_client_library.h (+0/-7)
include/server/mir/display_server.h (+0/-18)
include/server/mir/graphics/egl/mesa_native_display.h (+42/-0)
include/server/mir/graphics/platform.h (+5/-2)
include/server/mir/shell/focus_sequence.h (+2/-2)
include/shared/mir_toolkit/mesa/native_display.h (+3/-1)
include/test/mir_test_doubles/mock_surface.h (+1/-1)
include/test/mir_test_framework/testing_server_configuration.h (+1/-1)
src/client/gbm/mesa_native_display_container.cpp (+8/-1)
src/client/mir_client_library.cpp (+0/-5)
src/server/display_server.cpp (+1/-0)
src/server/graphics/CMakeLists.txt (+12/-2)
src/server/graphics/android/android_platform.cpp (+6/-0)
src/server/graphics/android/android_platform.h (+2/-0)
src/server/graphics/egl/CMakeLists.txt (+10/-0)
src/server/graphics/egl/mesa_native_display.cpp (+148/-0)
src/server/graphics/gbm/gbm_platform.cpp (+17/-5)
src/server/graphics/gbm/gbm_platform.h (+6/-0)
src/server/shell/application_session.cpp (+1/-1)
src/server/shell/single_visibility_focus_mechanism.cpp (+1/-1)
src/server/shell/surface.cpp (+1/-2)
src/server/shell/surface_source.cpp (+1/-2)
tests/acceptance-tests/test_client_input.cpp (+1/-1)
tests/acceptance-tests/test_test_framework.cpp (+1/-1)
tests/behavior-tests/session_management_context.cpp (+1/-1)
tests/integration-tests/graphics/gbm/test_buffer_integration.cpp (+5/-0)
tests/integration-tests/test_display_info.cpp (+4/-1)
tests/integration-tests/test_drm_auth_magic.cpp (+5/-0)
tests/integration-tests/test_surfaceloop.cpp (+10/-0)
tests/mir_test_framework/testing_process_manager.cpp (+1/-1)
tests/mir_test_framework/testing_server_options.cpp (+6/-1)
tests/unit-tests/client/gbm/test_gbm_client_platform.cpp (+6/-4)
tests/unit-tests/frontend/test_session_mediator.cpp (+6/-1)
tests/unit-tests/frontend/test_session_mediator_android.cpp (+5/-0)
tests/unit-tests/frontend/test_session_mediator_gbm.cpp (+5/-0)
tests/unit-tests/graphics/CMakeLists.txt (+1/-1)
tests/unit-tests/graphics/egl/CMakeLists.txt (+6/-0)
tests/unit-tests/graphics/egl/test_mirserver_mesa_egl_native_display.cpp (+207/-0)
tests/unit-tests/shell/test_application_session.cpp (+1/-1)
tests/unit-tests/shell/test_session_manager.cpp (+1/-1)
tests/unit-tests/shell/test_surface.cpp (+1/-1)
Changed in mir: | |
status: | New → Triaged |
importance: | Undecided → Medium |
information type: | Proprietary → Public |
Changed in mir: | |
assignee: | nobody → Robert Carr (robertcarr) |
status: | Triaged → In Progress |
Changed in mir: | |
milestone: | none → 0.0.3 |
Changed in mir: | |
status: | Fix Committed → Fix Released |
This seems to be enough:
=== modified file 'src/egl/ main/egldisplay .c' main/egldisplay .c 2012-10-05 07:09:03 +0000 main/egldisplay .c 2013-02-07 17:41:49 +0000 latform( EGLNativeDispla yType nativeDisplay) PLATFORM; PLATFORM;
--- src/egl/
+++ src/egl/
@@ -196,7 +196,7 @@
_EGLPlatformType
_eglGetNativeP
{
- static _EGLPlatformType native_platform = _EGL_INVALID_
+ _EGLPlatformType native_platform = _EGL_INVALID_
char *detection_method = NULL;
if (native_platform == _EGL_INVALID_ PLATFORM) {
=== modified file 'src/egl/ main/egldriver. c' main/egldriver. c 2011-07-02 09:21:31 +0000 main/egldriver. c 2013-02-07 17:26:23 +0000
--- src/egl/
+++ src/egl/
@@ -200,8 +200,8 @@
lib_handle lib;
_EGLDriver *drv;
- if (mod->Driver)
- return EGL_TRUE;
+// if (mod->Driver)
+// return EGL_TRUE;
if (mod->BuiltIn) {
lib = (lib_handle) NULL;