Mesa (staging/21.2): d3d12: Fix Linux fence wait return value
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Wed Nov 10 17:30:09 UTC 2021
Module: Mesa
Branch: staging/21.2
Commit: 4ba15a8f1156176f015515db0dfff5291d590cbe
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=4ba15a8f1156176f015515db0dfff5291d590cbe
Author: Jesse Natalie <jenatali at microsoft.com>
Date: Sat Aug 7 19:27:41 2021 -0700
d3d12: Fix Linux fence wait return value
zero is for success, nonzero is failure.
Fixes: 0b60d6a2 ("d3d12: Support Linux eventfds for fences")
Reviewed-by: Jason Ekstrand <jason at jlekstrand.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12268>
(cherry picked from commit accd8326c5cb78788f12e3066bb6654595c23a51)
---
.pick_status.json | 2 +-
src/gallium/drivers/d3d12/d3d12_fence.cpp | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/.pick_status.json b/.pick_status.json
index 60a30d780a3..330319f2f92 100644
--- a/.pick_status.json
+++ b/.pick_status.json
@@ -427,7 +427,7 @@
"description": "d3d12: Fix Linux fence wait return value",
"nominated": true,
"nomination_type": 1,
- "resolution": 0,
+ "resolution": 1,
"main_sha": null,
"because_sha": "0b60d6a24d405066c4077154095a76204c103cc1"
},
diff --git a/src/gallium/drivers/d3d12/d3d12_fence.cpp b/src/gallium/drivers/d3d12/d3d12_fence.cpp
index 453c72b55e8..72e2567a5f9 100644
--- a/src/gallium/drivers/d3d12/d3d12_fence.cpp
+++ b/src/gallium/drivers/d3d12/d3d12_fence.cpp
@@ -72,7 +72,7 @@ static bool
wait_event(HANDLE event, int event_fd, uint64_t timeout_ns)
{
int timeout_ms = (timeout_ns == PIPE_TIMEOUT_INFINITE) ? -1 : timeout_ns / 1000000;
- return sync_wait(event_fd, timeout_ms);
+ return sync_wait(event_fd, timeout_ms) == 0;
}
#endif
More information about the mesa-commit
mailing list