summaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers/egl/x11
diff options
context:
space:
mode:
authorChia-I Wu <[email protected]>2010-02-21 15:47:45 +0800
committerChia-I Wu <[email protected]>2010-02-21 15:50:33 +0800
commit1207482a0340bfe92e2ff764e55d619c8036a47d (patch)
tree23d6ec5d4bcb00962233a80ff3e2f55f808a960e /src/gallium/state_trackers/egl/x11
parentf96e8a033b212b54a80622839579c99dff2378fc (diff)
st/egl: Disable SHM in ximage backend.
With pipe_screen::update_buffer being called in st_validate_state, it is likely that softpipe will flush tile caches to a detached SHM segment. Disable SHM for now until a better solution is found.
Diffstat (limited to 'src/gallium/state_trackers/egl/x11')
-rw-r--r--src/gallium/state_trackers/egl/x11/native_x11.c13
1 files changed, 10 insertions, 3 deletions
diff --git a/src/gallium/state_trackers/egl/x11/native_x11.c b/src/gallium/state_trackers/egl/x11/native_x11.c
index 8eb542bd827..55f0d4d3083 100644
--- a/src/gallium/state_trackers/egl/x11/native_x11.c
+++ b/src/gallium/state_trackers/egl/x11/native_x11.c
@@ -141,9 +141,16 @@ native_create_display(EGLNativeDisplayType dpy)
if (!ndpy) {
EGLint level = (force_sw) ? _EGL_INFO : _EGL_WARNING;
-
- _eglLog(level, "use software fallback");
- ndpy = x11_create_ximage_display(dpy, TRUE);
+ boolean use_shm;
+
+ /*
+ * XXX st/mesa calls pipe_screen::update_buffer in st_validate_state.
+ * When SHM is used, there is a good chance that the shared memory
+ * segment is detached before the softpipe tile cache is flushed.
+ */
+ use_shm = FALSE;
+ _eglLog(level, "use software%s fallback", (use_shm) ? " (SHM)" : "");
+ ndpy = x11_create_ximage_display(dpy, use_shm);
}
return ndpy;