Mesa (staging/22.1): zink: never create a sw context unless sw is requested
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Wed May 18 02:46:08 UTC 2022
Module: Mesa
Branch: staging/22.1
Commit: fa325e152759b8235b8590d97417bcdab103ed07
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=fa325e152759b8235b8590d97417bcdab103ed07
Author: Mike Blumenkrantz <michael.blumenkrantz at gmail.com>
Date: Tue May 3 19:14:00 2022 -0400
zink: never create a sw context unless sw is requested
this otherwise makes it impossible to accurately do hardware driver
fallback, as zink will create a sw context instead of failing, superceding
the actual sw driver priorities
Reviewed-by: Dave Airlie <airlied at redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16572>
---
src/gallium/drivers/zink/zink_screen.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/gallium/drivers/zink/zink_screen.c b/src/gallium/drivers/zink/zink_screen.c
index cf299175c6f..ae35eaf2074 100644
--- a/src/gallium/drivers/zink/zink_screen.c
+++ b/src/gallium/drivers/zink/zink_screen.c
@@ -1318,7 +1318,7 @@ choose_pdev(struct zink_screen *screen)
}
}
is_cpu = cur_prio == prio_map[VK_PHYSICAL_DEVICE_TYPE_CPU];
- if (cpu && !is_cpu)
+ if (cpu != is_cpu)
goto out;
screen->pdev = pdevs[idx];
More information about the mesa-commit
mailing list