Mesa (main): zink: fix transient attachment rp assert

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Mon Jul 18 03:57:15 UTC 2022


Module: Mesa
Branch: main
Commit: 8bb5a115034548551b859f900849019d3f563cf0
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=8bb5a115034548551b859f900849019d3f563cf0

Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date:   Fri Jul 15 09:15:37 2022 -0400

zink: fix transient attachment rp assert

cc: mesa-stable

Acked-by: Dave Airlie <airlied at redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17366>

---

 src/gallium/drivers/zink/zink_render_pass.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gallium/drivers/zink/zink_render_pass.c b/src/gallium/drivers/zink/zink_render_pass.c
index 1332689456e..e037ef7ab29 100644
--- a/src/gallium/drivers/zink/zink_render_pass.c
+++ b/src/gallium/drivers/zink/zink_render_pass.c
@@ -576,7 +576,7 @@ begin_render_pass(struct zink_context *ctx)
             surf = zink_csurface(ctx->dummy_surface[util_logbase2_ceil(ctx->fb_state.samples)]);
             assert(zink_resource(surf->base.texture)->obj->vkusage == ctx->framebuffer->state.infos[i].usage);
          } else {
-            struct zink_surface *transient = zink_transient_surface(&surf->base);
+            struct zink_surface *transient = zink_transient_surface(ctx->fb_state.cbufs[i]);
             if (surf->base.format == ctx->fb_state.cbufs[i]->format) {
                if (transient) {
                   assert(zink_resource(transient->base.texture)->obj->vkusage == ctx->framebuffer->state.infos[i].usage);



More information about the mesa-commit mailing list