summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Anholt <eric@anholt.net>2009-01-15 09:31:55 -0800
committerEric Anholt <eric@anholt.net>2009-01-21 11:49:18 -0800
commite1c2f5d7afbd29dfb6f1e24589e13729ac71a2a7 (patch)
tree660d08ec2491b8acc5d817edc7182b20561c9d87
parent12ad7f650a01916fd05e0aee9a72f70b112e50a0 (diff)
Fix invarient state emits for DRI2 (do it per batch, since there's no lock).
(cherry picked from commit cab5b7a7b0e17414f98b2363b0961c87f32f9c05)
-rw-r--r--configure.ac2
-rw-r--r--src/i830_batchbuffer.c6
2 files changed, 7 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index bb69f726..249e9a93 100644
--- a/configure.ac
+++ b/configure.ac
@@ -209,7 +209,7 @@ if test "x$GCC" = "xyes"; then
-Wnested-externs -fno-strict-aliasing"
fi
-PKG_CHECK_MODULES(DRM, [libdrm >= 2.4.3])
+PKG_CHECK_MODULES(DRM, [libdrm >= 2.4.0])
AM_CONDITIONAL(DRI, test x$DRI = xyes)
if test "$DRI" = yes; then
PKG_CHECK_MODULES(DRI, [xf86driproto glproto])
diff --git a/src/i830_batchbuffer.c b/src/i830_batchbuffer.c
index b1c8a8de..671e8c87 100644
--- a/src/i830_batchbuffer.c
+++ b/src/i830_batchbuffer.c
@@ -117,6 +117,12 @@ intel_next_batch(ScrnInfoPtr pScrn)
pI830->batch_used = 0;
pI830->batch_ptr = pI830->batch_bo->virtual;
+
+ /* If we are using DRI2, we don't know when another client has executed,
+ * so we have to reinitialize our 3D state per batch.
+ */
+ if (pI830->directRenderingType == DRI_DRI2)
+ *pI830->last_3d = LAST_3D_OTHER;
}
void