From f132452da14fd09a2a3926cc9c034cb2e8c2f1a9 Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Tue, 19 Mar 2013 07:57:30 +0000 Subject: [PATCH] sna: Ignore vsync waits on tiny scanline ranges If the update is only a couple of lines tall, any tear will not be visible - so just ignore programming the wait into the GPU. Signed-off-by: Chris Wilson --- src/sna/sna_display.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sna/sna_display.c b/src/sna/sna_display.c index a80a3c16..abb340a7 100644 --- a/src/sna/sna_display.c +++ b/src/sna/sna_display.c @@ -3005,7 +3005,7 @@ sna_wait_for_scanline(struct sna *sna, if (y2 > crtc->bounds.y2 - crtc->bounds.y1) y2 = crtc->bounds.y2 - crtc->bounds.y1; DBG(("%s: clipped range = %d, %d\n", __FUNCTION__, y1, y2)); - if (y2 <= y1) + if (y2 <= y1 + 4) return false; full_height = y1 == 0 && y2 == crtc->bounds.y2 - crtc->bounds.y1;