diff options
author | Rhys Kidd <[email protected]> | 2018-12-17 01:25:11 -0500 |
---|---|---|
committer | Kenneth Graunke <[email protected]> | 2019-02-21 10:26:11 -0800 |
commit | 6c17e7d95f36a2f16fc8667243b3b469a2c601a7 (patch) | |
tree | ecf786210dbeec15c41a164bfab5a257fef143e6 | |
parent | 73d525f1883a67a19d30b66d4e30788e781cc436 (diff) |
iris: Fix assertion in iris_resource_from_handle() tiling usage
Assertion error:
iris_resource_from_handle: Assertion `res->bo->tiling_mode ==
isl_tiling_to_i915_tiling(res->surf.tiling)' failed.
This patch fixes 16 piglit tests on KBL:
glx/glx-multithread-texture
glx/glx-query-drawable-glx_fbconfig_id-glxpbuffer
glx/glx-query-drawable-glx_fbconfig_id-glxpixmap
glx/glx-query-drawable-glx_preserved_contents
glx/glx-query-drawable-glxpbuffer-glx_height
glx/glx-query-drawable-glxpbuffer-glx_width
glx/glx-query-drawable-glxpixmap-glx_height
glx/glx-query-drawable-glxpixmap-glx_width
glx/glx-swap-pixmap
glx/glx-swap-pixmap-bad
glx/glx-tfp
glx/glx-visuals-depth -pixmap
glx/glx-visuals-stencil -pixmap
spec/egl 1.4/eglcreatepbuffersurface and then glclear
spec/egl 1.4/largest possible eglcreatepbuffersurface and then glclear
spec/egl_nok_texture_from_pixmap/basic
Cc: Kenneth Graunke <[email protected]>
Cc: Jason Ekstrand <[email protected]>
Signed-off-by: Rhys Kidd <[email protected]>
-rw-r--r-- | src/gallium/drivers/iris/iris_resource.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/gallium/drivers/iris/iris_resource.c b/src/gallium/drivers/iris/iris_resource.c index 3b8b0f51101..1117ebec15d 100644 --- a/src/gallium/drivers/iris/iris_resource.c +++ b/src/gallium/drivers/iris/iris_resource.c @@ -465,8 +465,7 @@ iris_resource_from_handle(struct pipe_screen *pscreen, isl_drm_modifier_get_info(modifier); assert(mod_info); - // XXX: usage... - isl_surf_usage_flags_t isl_usage = ISL_SURF_USAGE_DISPLAY_BIT; + isl_surf_usage_flags_t isl_usage = pipe_bind_to_isl_usage(templ->bind); const struct iris_format_info fmt = iris_format_for_usage(devinfo, templ->format, isl_usage); |