[PATCH 07/12] DRI2: handle swap_interval of 0 correctly

Jesse Barnes jbarnes at virtuousgeek.org
Mon Mar 22 15:03:37 PDT 2010


A 0 swap interval means that swaps shouldn't be sync'd to vblank, so
just complete the swap immediately in that case.

Signed-off-by: Jesse Barnes <jbarnes at virtuousgeek.org>
---
 hw/xfree86/dri2/dri2.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/hw/xfree86/dri2/dri2.c b/hw/xfree86/dri2/dri2.c
index f2c073f..eb61526 100644
--- a/hw/xfree86/dri2/dri2.c
+++ b/hw/xfree86/dri2/dri2.c
@@ -616,8 +616,8 @@ DRI2SwapBuffers(ClientPtr client, DrawablePtr pDraw, CARD64 target_msc,
 	return BadDrawable;
     }
 
-    /* Old DDX, just blit */
-    if (!ds->ScheduleSwap) {
+    /* Old DDX or no swap interval, just blit */
+    if (!ds->ScheduleSwap || !pPriv->swap_interval) {
 	BoxRec box;
 	RegionRec region;
 
-- 
1.6.6.1



More information about the xorg-devel mailing list