summaryrefslogtreecommitdiff
path: root/src/sna
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2013-06-19 19:53:14 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2013-06-19 19:53:14 +0100
commit112fc5f370f8daf267d7241ca2d669194abaa183 (patch)
tree1451548d6793fb9a498335a041ebf474c992ac3c /src/sna
parentba642d9ff86fcf8b0b758d65565e3b5b6293b667 (diff)
sna: Tidy a redundant conditional for CopyArea
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/sna')
-rw-r--r--src/sna/sna_accel.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/sna/sna_accel.c b/src/sna/sna_accel.c
index 0f5c392e..9cbecfe2 100644
--- a/src/sna/sna_accel.c
+++ b/src/sna/sna_accel.c
@@ -4325,6 +4325,9 @@ move_to_gpu(PixmapPtr pixmap, struct sna_pixmap *priv,
}
if (priv->gpu_bo) {
+ if (priv->cpu_damage == NULL)
+ return true;
+
if (alu != GXcopy)
return true;
@@ -4763,7 +4766,7 @@ sna_copy_boxes(DrawablePtr src, DrawablePtr dst, GCPtr gc,
if (replaces)
kgem_bo_undo(&sna->kgem, bo);
- if (replaces && alu == GXcopy &&
+ if (replaces &&
src_pixmap->drawable.width == dst_pixmap->drawable.width &&
src_pixmap->drawable.height == dst_pixmap->drawable.height) {
assert(src_pixmap->drawable.depth == dst_pixmap->drawable.depth);