summaryrefslogtreecommitdiff
path: root/src/sna/sna_accel.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2012-11-21 16:22:35 +0000
committerChris Wilson <chris@chris-wilson.co.uk>2012-11-21 16:22:35 +0000
commit44dad490140d85a4c0dcb916030c36a838670c01 (patch)
treec32b88b73ed1506077df61cf93f6d1fd42fa3bf1 /src/sna/sna_accel.c
parent9c627a05247690891062a2c0c1c8f7bbc0273104 (diff)
sna: Do not dispose of a shadow pixmap
Fixes regression from 2249e9edc37811c07e2807d6b4def05585b44c22 Reported-by: Jiri Slaby <jirislaby@gmail.com> References: https://bugs.freedesktop.org/show_bug.cgi?id=47597 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/sna/sna_accel.c')
-rw-r--r--src/sna/sna_accel.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c
index 4b0d014a..b38f80fe 100644
--- a/src/sna/sna_accel.c
+++ b/src/sna/sna_accel.c
@@ -3156,7 +3156,8 @@ sna_pixmap_move_to_gpu(PixmapPtr pixmap, unsigned flags)
}
/* For large bo, try to keep only a single copy around */
- if (priv->create & KGEM_CAN_CREATE_LARGE || flags & MOVE_SOURCE_HINT) {
+ if (priv->create & KGEM_CAN_CREATE_LARGE ||
+ (priv->stride && flags & MOVE_SOURCE_HINT)) {
DBG(("%s: disposing of system copy for large/source\n",
__FUNCTION__));
assert(!priv->shm);