diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2015-02-14 21:53:41 +0000 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2015-02-14 22:43:13 +0000 |
commit | c30af937f8d634d0055358cb69db2896cf595983 (patch) | |
tree | 6139278c862ed50e60f92f4a9cd2bb49e3bbeb20 /src | |
parent | 9a311f9da612ba02b24458f6a40b6a5445ad4869 (diff) |
sna/present: Disable hardware async flips with TearFree
These two don't mix, so remove the claim that we do support async flips
when TearFree is enabled.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src')
-rw-r--r-- | src/sna/sna_display.c | 2 | ||||
-rw-r--r-- | src/sna/sna_present.c | 4 |
2 files changed, 2 insertions, 4 deletions
diff --git a/src/sna/sna_display.c b/src/sna/sna_display.c index c95fe98f..286e4701 100644 --- a/src/sna/sna_display.c +++ b/src/sna/sna_display.c @@ -5973,7 +5973,7 @@ probe_capabilities(struct sna *sna) sna->flags &= ~(SNA_HAS_FLIP | SNA_HAS_ASYNC_FLIP); if (has_flip(sna)) sna->flags |= SNA_HAS_FLIP; - if (has_flip__async(sna)) + if (has_flip__async(sna) && (sna->flags & SNA_TEAR_FREE) == 0) sna->flags |= SNA_HAS_ASYNC_FLIP; DBG(("%s: page flips? %s, async? %s\n", __FUNCTION__, sna->flags & SNA_HAS_FLIP ? "enabled" : "disabled", diff --git a/src/sna/sna_present.c b/src/sna/sna_present.c index 6cc9c2e3..266d7432 100644 --- a/src/sna/sna_present.c +++ b/src/sna/sna_present.c @@ -562,15 +562,13 @@ xchg(struct sna *sna, assert(sna->flags & SNA_TEAR_FREE); assert(sna->mode.shadow_damage); assert(sna_pixmap(pixmap) && sna_pixmap(pixmap)->gpu_bo); + assert(sync_flip); /* This effectively disables TearFree giving the client direct * access into the scanout with their Pixmap. */ queued = set_front(sna, pixmap); - if (!sync_flip) - goto notify; /* XXX We will claim that the scanout is idle */ - info = malloc(sizeof(struct sna_present_event)); if (info == NULL) return BadAlloc; |