aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/panfrost
diff options
context:
space:
mode:
authorDaniel Ogorchock <[email protected]>2020-01-07 10:07:37 -0600
committerTomeu Vizoso <[email protected]>2020-01-13 09:11:35 +0000
commit632885741f74c12dedd4f128bba45e6a7f8d8982 (patch)
tree0e17bd9531b200867c4f8abc3951cac938a3cbc3 /src/gallium/drivers/panfrost
parent2848edc0eff5570abaac0a4017a9c96ebabbd728 (diff)
panfrost: Fix headers and gpu_headers memory leak
The per-batch headers/gpu_headers dynarrays need to be freed during the batch cleanup to prevent leaking. Signed-off-by: Daniel Ogorchock <[email protected]> Reviewed-by: Alyssa Rosenzweig <[email protected]> Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3308> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3308>
Diffstat (limited to 'src/gallium/drivers/panfrost')
-rw-r--r--src/gallium/drivers/panfrost/pan_job.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gallium/drivers/panfrost/pan_job.c b/src/gallium/drivers/panfrost/pan_job.c
index d1ce9c0ec33..1b7d370b998 100644
--- a/src/gallium/drivers/panfrost/pan_job.c
+++ b/src/gallium/drivers/panfrost/pan_job.c
@@ -181,6 +181,9 @@ panfrost_free_batch(struct panfrost_batch *batch)
panfrost_batch_fence_unreference(*dep);
}
+ util_dynarray_fini(&batch->headers);
+ util_dynarray_fini(&batch->gpu_headers);
+
/* The out_sync fence lifetime is different from the the batch one
* since other batches might want to wait on a fence of already
* submitted/signaled batch. All we need to do here is make sure the