Mesa (staging/21.3): iris: fix a leak on surface states
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Sun Feb 20 17:40:40 UTC 2022
Module: Mesa
Branch: staging/21.3
Commit: 4d6535700dc1f2f1a8ba1bcaff8fb0772726acb0
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=4d6535700dc1f2f1a8ba1bcaff8fb0772726acb0
Author: Tapani Pälli <tapani.palli at intel.com>
Date: Mon Feb 14 07:40:51 2022 +0200
iris: fix a leak on surface states
Cc: mesa-stable
Closes:https://gitlab.freedesktop.org/mesa/mesa/-/issues/6013
Signed-off-by: Tapani Pälli <tapani.palli at intel.com>
Reviewed-by: Nanley Chery <nanley.g.chery at intel.com>
Reviewed-by: Kenneth Graunke <kenneth at whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15010>
(cherry picked from commit ecc00410302cae4e22ad7718a531f03658190389)
---
.pick_status.json | 2 +-
src/gallium/drivers/iris/iris_state.c | 1 +
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/.pick_status.json b/.pick_status.json
index 4567bddcd86..9d53a7e3ee4 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -1354,7 +1354,7 @@
"description": "iris: fix a leak on surface states",
"nominated": true,
"nomination_type": 0,
- "resolution": 0,
+ "resolution": 1,
"main_sha": null,
"because_sha": null
},
diff --git a/src/gallium/drivers/iris/iris_state.c b/src/gallium/drivers/iris/iris_state.c
index e4c4f7095e6..40dc2d062d1 100644
--- a/src/gallium/drivers/iris/iris_state.c
+++ b/src/gallium/drivers/iris/iris_state.c
@@ -2934,6 +2934,7 @@ iris_surface_destroy(struct pipe_context *ctx, struct pipe_surface *p_surf)
pipe_resource_reference(&surf->surface_state.ref.res, NULL);
pipe_resource_reference(&surf->surface_state_read.ref.res, NULL);
free(surf->surface_state.cpu);
+ free(surf->surface_state_read.cpu);
free(surf);
}
More information about the mesa-commit
mailing list