forked from gentoo/gentoo
-
Notifications
You must be signed in to change notification settings - Fork 0
/
cogl-1.22.0-wait-flip.patch
42 lines (34 loc) · 1.29 KB
/
cogl-1.22.0-wait-flip.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
From a583492ea2aa3ea8e78c269bd5db3f52f82aa79c Mon Sep 17 00:00:00 2001
From: Ray Strode <[email protected]>
Date: Wed, 21 Oct 2015 15:47:01 -0400
Subject: kms-winsys: don't wait for a flip when page flipping fails
If we get EACCES from drmPageFlip we're not going to get
a flip event and shouldn't wait for one.
This commit changes the EACCES path to silently ignore the
failed flip request and just clean up the fb.
https://bugzilla.gnome.org/show_bug.cgi?id=756926
---
cogl/winsys/cogl-winsys-egl-kms.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/cogl/winsys/cogl-winsys-egl-kms.c b/cogl/winsys/cogl-winsys-egl-kms.c
index 20c325c..b460907 100644
--- a/cogl/winsys/cogl-winsys-egl-kms.c
+++ b/cogl/winsys/cogl-winsys-egl-kms.c
@@ -590,7 +590,7 @@ flip_all_crtcs (CoglDisplay *display, CoglFlipKMS *flip, int fb_id)
for (l = kms_display->crtcs; l; l = l->next)
{
CoglKmsCrtc *crtc = l->data;
- int ret;
+ int ret = 0;
if (crtc->count == 0 || crtc->ignore)
continue;
@@ -610,7 +610,8 @@ flip_all_crtcs (CoglDisplay *display, CoglFlipKMS *flip, int fb_id)
}
}
- flip->pending++;
+ if (ret == 0)
+ flip->pending++;
}
if (kms_renderer->page_flips_not_supported && needs_flip)
--
cgit v0.11.2