etnaviv: drm: fix BO array leaks

Free the both arrays tracking BOs when the etna_cmd_stream is destroyed.

CC: mesa-stable
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Reviewed-by: Christian Gmeiner <christian.gmeiner@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20940>
(cherry picked from commit 3156b15f70)
This commit is contained in:
Lucas Stach 2023-01-26 12:38:35 +01:00 committed by Dylan Baker
parent e2153c29fe
commit 19f9d41f80
2 changed files with 3 additions and 1 deletions

View file

@ -418,7 +418,7 @@
"description": "etnaviv: drm: fix BO array leaks",
"nominated": true,
"nomination_type": 0,
"resolution": 0,
"resolution": 1,
"main_sha": null,
"because_sha": null
},

View file

@ -135,6 +135,8 @@ void etna_cmd_stream_del(struct etna_cmd_stream *stream)
_mesa_hash_table_destroy(priv->bo_table, NULL);
free(stream->buffer);
free(priv->bos);
free(priv->submit.bos);
free(priv->submit.relocs);
free(priv->submit.pmrs);
free(priv);