[igt-dev] [PATCH i-g-t 1/3] lib/intel_bufops: Relax swizzle condition to allow using software tiling

Zbigniew Kempczyński zbigniew.kempczynski at intel.com
Tue Jan 25 06:52:29 UTC 2022


On gen8+ or VLV i915 doesn't set swizzle bits so disabling software
tiling when we're not able to get swizzle bits (via GEM_SET_TILING)
is not necessary.

Software tiling is useful for detecting correctness of tiled surfaces
produced by render-copy or fast-copy.

Signed-off-by: Zbigniew Kempczyński <zbigniew.kempczynski at intel.com>
Cc: Petri Latvala <petri.latvala at intel.com>
Cc: Ashutosh Dixit <ashutosh.dixit at intel.com>
---
 lib/intel_bufops.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/intel_bufops.c b/lib/intel_bufops.c
index f13063fa9..e8160c823 100644
--- a/lib/intel_bufops.c
+++ b/lib/intel_bufops.c
@@ -1359,7 +1359,7 @@ static struct buf_ops *__buf_ops_create(int fd, bool check_idempotency)
 		bool supported = probe_hw_tiling(bops, I915_TILING_X,
 						 &swizzling_supported);
 
-		if (!swizzling_supported) {
+		if (!swizzling_supported && bops->intel_gen < 8) {
 			igt_debug("Swizzling for X is not supported\n");
 			bops->supported_tiles &= ~TILE_X;
 		}
@@ -1377,7 +1377,7 @@ static struct buf_ops *__buf_ops_create(int fd, bool check_idempotency)
 		bool supported = probe_hw_tiling(bops, I915_TILING_Y,
 						 &swizzling_supported);
 
-		if (!swizzling_supported) {
+		if (!swizzling_supported && bops->intel_gen < 8) {
 			igt_debug("Swizzling for Y is not supported\n");
 			bops->supported_tiles &= ~TILE_Y;
 		}
-- 
2.32.0



More information about the igt-dev mailing list