summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/freedreno/freedreno_context.c
diff options
context:
space:
mode:
authorRob Clark <[email protected]>2015-07-26 13:30:26 -0400
committerRob Clark <[email protected]>2015-07-27 13:51:06 -0400
commitbda1354aac9d32e236048af4d353d5530f644c34 (patch)
treec576969a93da91735c2136c6d9076c515369bb11 /src/gallium/drivers/freedreno/freedreno_context.c
parent65d36a109a7dd333c15180a0f30ad919eb01d78f (diff)
freedreno: add resource tracking support for written buffers
With stream-out (transform-feedback) we have the case where resources are *written* by the gpu, which needs basically the same tracking to figure out when rendering must be flushed. Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/gallium/drivers/freedreno/freedreno_context.c')
-rw-r--r--src/gallium/drivers/freedreno/freedreno_context.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gallium/drivers/freedreno/freedreno_context.c b/src/gallium/drivers/freedreno/freedreno_context.c
index 127fb5f5aa0..02613dcdbdb 100644
--- a/src/gallium/drivers/freedreno/freedreno_context.c
+++ b/src/gallium/drivers/freedreno/freedreno_context.c
@@ -130,8 +130,9 @@ fd_context_render(struct pipe_context *pctx)
/* go through all the used resources and clear their reading flag */
LIST_FOR_EACH_ENTRY_SAFE(rsc, rsc_tmp, &ctx->used_resources, list) {
- assert(rsc->reading);
+ assert(rsc->reading || rsc->writing);
rsc->reading = false;
+ rsc->writing = false;
list_delinit(&rsc->list);
}