From 708255cbca83dbafe9154c39bd4553b0b81f09cf Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Wed, 20 Dec 2017 08:46:43 +0000 Subject: [PATCH] sna: Drop redundant sync of an inactive snoop cache Having requested an inactive snooped buffer, we know that it is already flushed and do not need to flush it again. With debugging enabled, we hit an assert while flushing that the buffer has a refcout, which at this present time of being plucked from the snoop cache it does not. Reported-by: Adric Blake References: https://bugs.freedesktop.org/show_bug.cgi?id=104341#c2 Signed-off-by: Chris Wilson --- src/sna/kgem.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/sna/kgem.c b/src/sna/kgem.c index e58db967..038ecc87 100644 --- a/src/sna/kgem.c +++ b/src/sna/kgem.c @@ -3600,7 +3600,6 @@ static void kgem_finish_buffers(struct kgem *kgem) assert(bo->used <= bytes(shrink)); map = kgem_bo_map__cpu(kgem, shrink); if (map) { - kgem_bo_sync__cpu(kgem, shrink); memcpy(map, bo->mem, bo->used); shrink->target_handle =