summaryrefslogtreecommitdiff
path: root/src/sna/sna_render.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2014-06-06 16:58:45 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2014-06-06 22:13:06 +0100
commita378196fddcf3043257a7e56225060e5e36cfa7b (patch)
treeed81ef5b38f383c6619f695e825a90db5b988a0b /src/sna/sna_render.c
parent23840bd329cf4da3a4bdd5a1a466125a95473534 (diff)
sna: Auto-retire upload proxies
This was disabled in commit 9f4f855ba37966fb91d31e9081d03cf72affb154 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Mon May 26 07:06:18 2014 +0100 sna: Implicit release of upload buffers considered bad as retiring the buffers during the command setup could free one of the earlier bo used in the command. But discarding the snooped bo could still be advantageous. So restore the automatic discard of upload proxies, but make sure we only do between operations. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Matti Hämäläinen <ccr@tnsp.org>
Diffstat (limited to 'src/sna/sna_render.c')
-rw-r--r--src/sna/sna_render.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/sna/sna_render.c b/src/sna/sna_render.c
index b03134d6..e58b6e1d 100644
--- a/src/sna/sna_render.c
+++ b/src/sna/sna_render.c
@@ -565,7 +565,7 @@ static struct kgem_bo *upload(struct sna *sna,
assert(priv->gpu_damage == NULL);
assert(priv->gpu_bo == NULL);
assert(bo->proxy != NULL);
- priv->gpu_bo = kgem_bo_reference(bo);
+ kgem_proxy_bo_attach(bo, &priv->gpu_bo);
}
}
@@ -1271,7 +1271,7 @@ sna_render_picture_extract(struct sna *sna,
assert(priv->gpu_damage == NULL);
assert(priv->gpu_bo == NULL);
assert(bo->proxy != NULL);
- priv->gpu_bo = kgem_bo_reference(bo);
+ kgem_proxy_bo_attach(bo, &priv->gpu_bo);
}
}