zink: Fix missing sparse buffer bind synchronization.
authorTatsuyuki Ishi <ishitatsuyuki@gmail.com>
Mon, 13 Nov 2023 08:39:20 +0000 (17:39 +0900)
committerEric Engestrom <eric@engestrom.ch>
Sat, 18 Nov 2023 21:15:16 +0000 (21:15 +0000)
goto oopsies.

Fixes: d1456a6b0ad ("zink: add semaphore handling for sparse binds")
Reviewed-by: Dave Airlie <airlied@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26171>
(cherry picked from commit 3ee283e45557066c29fdb2000f7627d8996aeed0)

.pick_status.json
src/gallium/drivers/zink/zink_bo.c

index a264889..74002f0 100644 (file)
         "description": "zink: Fix missing sparse buffer bind synchronization.",
         "nominated": true,
         "nomination_type": 1,
-        "resolution": 0,
+        "resolution": 1,
         "main_sha": null,
         "because_sha": "d1456a6b0ad0dee9936caa52c9fd915c4bfaa61b",
         "notes": null
index 7fd2bd4..0194974 100644 (file)
@@ -959,7 +959,7 @@ zink_bo_commit(struct zink_screen *screen, struct zink_resource *res, unsigned l
    simple_mtx_lock(&screen->queue_lock);
    simple_mtx_lock(&bo->lock);
    if (res->base.b.target == PIPE_BUFFER) {
-      ok = buffer_bo_commit(screen, res, box->x, box->width, commit, sem);
+      ok = buffer_bo_commit(screen, res, box->x, box->width, commit, &cur_sem);
       goto out;
    }