Mesa (staging/21.3): crocus: fix leak on gen4/5 stencil fallback blit path.

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Mon Feb 21 20:51:20 UTC 2022


Module: Mesa
Branch: staging/21.3
Commit: 7238f8c64a9095bb0a52a4bb86c7278cfbf3f6fe
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=7238f8c64a9095bb0a52a4bb86c7278cfbf3f6fe

Author: Dave Airlie <airlied at redhat.com>
Date:   Mon Feb 21 09:35:00 2022 +1000

crocus: fix leak on gen4/5 stencil fallback blit path.

Noticed by Ilia.

Fixes: f3630548f1da ("crocus: initial gallium driver for Intel gfx 4-7")

Reviewed-by: Ilia Mirkin <imirkin at alum.mit.edu>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15100>
(cherry picked from commit 0f989a840efda4aedee2dbf009c400c428be01d7)

---

 .pick_status.json                        | 2 +-
 src/gallium/drivers/crocus/crocus_blit.c | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/.pick_status.json b/.pick_status.json
index 0cedd72e25d..786d88ff367 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -382,7 +382,7 @@
         "description": "crocus: fix leak on gen4/5 stencil fallback blit path.",
         "nominated": true,
         "nomination_type": 1,
-        "resolution": 0,
+        "resolution": 1,
         "main_sha": null,
         "because_sha": "f3630548f1da904ec6c63b43ece7e68afdb8867e"
     },
diff --git a/src/gallium/drivers/crocus/crocus_blit.c b/src/gallium/drivers/crocus/crocus_blit.c
index 7620efc932b..67c10e7c00e 100644
--- a/src/gallium/drivers/crocus/crocus_blit.c
+++ b/src/gallium/drivers/crocus/crocus_blit.c
@@ -433,6 +433,7 @@ crocus_blit(struct pipe_context *ctx, const struct pipe_blit_info *info)
                                              info->src.level,
                                              &info->src.box, NULL);
 
+               pipe_surface_release(ctx, &dst_view);
             }
             return;
          }



More information about the mesa-commit mailing list