Mesa (staging/19.2): iris: Default to X-tiling for scanout buffers without modifiers
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Mon Dec 16 23:17:36 UTC 2019
Module: Mesa
Branch: staging/19.2
Commit: 06b97d1e34fc34c2fd6aea16902e882cbe24f4d5
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=06b97d1e34fc34c2fd6aea16902e882cbe24f4d5
Author: Kenneth Graunke <kenneth at whitecape.org>
Date: Wed Dec 11 09:49:38 2019 -0800
iris: Default to X-tiling for scanout buffers without modifiers
Neither Mutter nor KWin's wayland compositors appear to use modifiers.
In the non-modifier case, iris was still trying to use Y-tiling for
scan-out surfaces, leading to this error:
(gnome-shell:7247): mutter-WARNING **: 09:23:47.787: meta_drm_buffer_gbm_new failed: drmModeAddFB failed: Invalid argument
We now fall back to the historical X-tiling for scanout buffers, which
ought to work everyone, at lower performance. To regain that, we need
to ensure modifiers are actually supported in environments people use.
Fixes: fbf31247710 ("iris: Rework tiling/modifiers handling")
Reviewed-by: Jason Ekstrand <jason at jlekstrand.net>
(cherry picked from commit dcb4230e5e51c1f2ff84c436134c231996af85e9)
---
src/gallium/drivers/iris/iris_resource.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/gallium/drivers/iris/iris_resource.c b/src/gallium/drivers/iris/iris_resource.c
index 7b708a1d3c9..49f0c4f792a 100644
--- a/src/gallium/drivers/iris/iris_resource.c
+++ b/src/gallium/drivers/iris/iris_resource.c
@@ -739,6 +739,8 @@ iris_resource_create_with_modifiers(struct pipe_screen *pscreen,
if (templ->usage == PIPE_USAGE_STAGING ||
templ->bind & (PIPE_BIND_LINEAR | PIPE_BIND_CURSOR) )
tiling_flags = ISL_TILING_LINEAR_BIT;
+ else if (templ->bind & PIPE_BIND_SCANOUT)
+ tiling_flags = ISL_TILING_X_BIT;
}
isl_surf_usage_flags_t usage = pipe_bind_to_isl_usage(templ->bind);
More information about the mesa-commit
mailing list