diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2014-04-29 13:29:45 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2014-04-29 13:56:33 +0100 |
commit | d75501572a4ea95fc126314718468345630723a1 (patch) | |
tree | 7a572597f63b45ea83d4f205ed1d05bb8a399268 /src | |
parent | 94e39323772ef6561efcc0620f67cabd2462a0d0 (diff) |
sna: Preserve cpu hint for compatible mmapping of the GPU bo
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src')
-rw-r--r-- | src/sna/sna_accel.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c index 677db403..b64855cd 100644 --- a/src/sna/sna_accel.c +++ b/src/sna/sna_accel.c @@ -2028,7 +2028,7 @@ _sna_pixmap_move_to_cpu(PixmapPtr pixmap, unsigned int flags) assert(!priv->shm); assert(priv->cpu_bo == NULL || !priv->cpu_bo->flush); sna_pixmap_free_cpu(sna, priv, priv->cpu); - priv->cpu = false; + priv->cpu &= priv->mapped == MAPPED_CPU; assert_pixmap_damage(pixmap); return true; @@ -2089,7 +2089,7 @@ skip_inplace_map: list_del(&priv->flush_list); priv->clear = false; } - priv->cpu = false; + priv->cpu &= priv->mapped == MAPPED_CPU; assert_pixmap_damage(pixmap); DBG(("%s: operate inplace (GTT)\n", __FUNCTION__)); @@ -2579,7 +2579,7 @@ sna_drawable_move_region_to_cpu(DrawablePtr drawable, } priv->clear = false; } - priv->cpu = false; + priv->cpu &= priv->mapped == MAPPED_CPU; assert_pixmap_damage(pixmap); if (dx | dy) RegionTranslate(region, -dx, -dy); |