Mesa (master): iris: fix fallback to swrast driver
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Fri Jul 10 17:53:42 UTC 2020
Module: Mesa
Branch: master
Commit: e3ddba73241901a75844b39e6e3b12eaf15f9b26
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=e3ddba73241901a75844b39e6e3b12eaf15f9b26
Author: Lionel Landwerlin <lionel.g.landwerlin at intel.com>
Date: Fri Jul 10 10:46:53 2020 +0300
iris: fix fallback to swrast driver
The helper we use to query the kernel returns -1 if the getparam is
not supported.
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin at intel.com>
Fixes: f402b7c57641dd ("iris: fail screen creation when kernel support is not there")
Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/3188
Reviewed-by: Marcin Ślusarz <marcin.slusarz at intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5838>
---
src/gallium/drivers/iris/iris_screen.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/gallium/drivers/iris/iris_screen.c b/src/gallium/drivers/iris/iris_screen.c
index 373a3533dc4..dc2295689ea 100644
--- a/src/gallium/drivers/iris/iris_screen.c
+++ b/src/gallium/drivers/iris/iris_screen.c
@@ -675,7 +675,7 @@ iris_screen_create(int fd, const struct pipe_screen_config *config)
*
* Checking the last feature availability will include all previous ones.
*/
- if (!iris_getparam_integer(fd, I915_PARAM_HAS_CONTEXT_ISOLATION)) {
+ if (iris_getparam_integer(fd, I915_PARAM_HAS_CONTEXT_ISOLATION) <= 0) {
debug_error("Kernel is too old for Iris. Consider upgrading to kernel v4.16.\n");
return NULL;
}
More information about the mesa-commit
mailing list