diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2014-01-10 21:08:28 +0000 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2014-01-10 21:38:44 +0000 |
commit | 9a0a1329391cc7d3047fea4b3d968afc7c6099b4 (patch) | |
tree | c90ae0d8d39dc888605cfa4fa7e705e7c4bad0b6 /src/sna/kgem.c | |
parent | b351f4a0009ce0eddb5866bd49ac59860a44f522 (diff) |
sna: Handle release of active stolen scanouts
If the scanout is still active we want to defer our release until the
request is retired.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/sna/kgem.c')
-rw-r--r-- | src/sna/kgem.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/sna/kgem.c b/src/sna/kgem.c index 187e4ff5..5d34bbc7 100644 --- a/src/sna/kgem.c +++ b/src/sna/kgem.c @@ -1867,10 +1867,12 @@ static void kgem_bo_move_to_scanout(struct kgem *kgem, struct kgem_bo *bo) assert(!bo->snoop); assert(!bo->io); - if (bo->purged) { - DBG(("%s: discarding purged scanout - external name?\n", - __FUNCTION__)); - kgem_bo_free(kgem, bo); + if (bo->purged) { /* for stolen fb */ + if (!bo->exec) { + DBG(("%s: discarding purged scanout - stolen?\n", + __FUNCTION__)); + kgem_bo_free(kgem, bo); + } return; } |