softpipe: use util_unreference_framebuffer_state to unref fb state

Fixes: f5bde99cbd ("gallium: plumb resolve attachments through from frontends -> pipe_framebuffer_state")

Reviewed-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22673>
(cherry picked from commit 4809274c18)
This commit is contained in:
Mike Blumenkrantz 2023-04-24 16:24:56 -04:00 committed by Eric Engestrom
parent 95354d8285
commit d8b3feeb8a
2 changed files with 2 additions and 3 deletions

View file

@ -661,7 +661,7 @@
"description": "softpipe: use util_unreference_framebuffer_state to unref fb state",
"nominated": true,
"nomination_type": 1,
"resolution": 0,
"resolution": 1,
"main_sha": null,
"because_sha": "f5bde99cbdd208916795dc463663ddd97428ecc1"
},

View file

@ -83,11 +83,10 @@ softpipe_destroy( struct pipe_context *pipe )
for (i = 0; i < PIPE_MAX_COLOR_BUFS; i++) {
sp_destroy_tile_cache(softpipe->cbuf_cache[i]);
pipe_surface_reference(&softpipe->framebuffer.cbufs[i], NULL);
}
sp_destroy_tile_cache(softpipe->zsbuf_cache);
pipe_surface_reference(&softpipe->framebuffer.zsbuf, NULL);
util_unreference_framebuffer_state(&softpipe->framebuffer);
for (sh = 0; sh < ARRAY_SIZE(softpipe->tex_cache); sh++) {
for (i = 0; i < ARRAY_SIZE(softpipe->tex_cache[0]); i++) {