Mesa (master): panfrost: Fix fence leak
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Mon Jul 13 14:59:52 UTC 2020
Module: Mesa
Branch: master
Commit: 20dd37024b045881d98a55b1927b0dab29d1edd3
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=20dd37024b045881d98a55b1927b0dab29d1edd3
Author: Alyssa Rosenzweig <alyssa.rosenzweig at collabora.com>
Date: Tue May 26 16:57:44 2020 -0400
panfrost: Fix fence leak
When overwriting the writer, we need to release the old reference.
Signed-off-by: Alyssa Rosenzweig <alyssa.rosenzweig at collabora.com>
Reviewed-by: Boris Brezillon <boris.brezillon at collabora.com>
Fixes: 2dad9fde505 ("panfrost: Start tracking inter-batch dependencies")
Cc: mesa-stable
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5859>
---
src/gallium/drivers/panfrost/pan_job.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/gallium/drivers/panfrost/pan_job.c b/src/gallium/drivers/panfrost/pan_job.c
index fb98b9a4bab..929bd993e74 100644
--- a/src/gallium/drivers/panfrost/pan_job.c
+++ b/src/gallium/drivers/panfrost/pan_job.c
@@ -462,6 +462,9 @@ panfrost_batch_update_bo_access(struct panfrost_batch *batch,
}
panfrost_batch_fence_reference(batch->out_sync);
+ if (access->writer)
+ panfrost_batch_fence_unreference(access->writer);
+
/* We now are the new writer. */
access->writer = batch->out_sync;
access->type = access_type;
More information about the mesa-commit
mailing list