public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH i-g-t] i915/gem_tiling_max_stride: Skip if chipset is unknown
@ 2019-04-26  7:56 Chris Wilson
  2019-04-26  8:20 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Chris Wilson @ 2019-04-26  7:56 UTC (permalink / raw)
  To: intel-gfx; +Cc: igt-dev

If we can't match the devid to a chipset, we do not have a reference for
the tiling strides. Instead of randomly failing, skip with a
semi-informative message.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=110523
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
 tests/i915/gem_tiling_max_stride.c | 16 +++++++++-------
 1 file changed, 9 insertions(+), 7 deletions(-)

diff --git a/tests/i915/gem_tiling_max_stride.c b/tests/i915/gem_tiling_max_stride.c
index a6f97a915..0e99d979f 100644
--- a/tests/i915/gem_tiling_max_stride.c
+++ b/tests/i915/gem_tiling_max_stride.c
@@ -72,16 +72,18 @@ igt_simple_main
 
 	devid = intel_get_drm_devid(fd);
 
-	if (intel_gen(devid) >= 7)
+	if (intel_gen(devid) >= 7) {
 		stride = 256 * 1024;
-	else if (intel_gen(devid) >= 4)
+	} else if (intel_gen(devid) >= 4) {
 		stride = 128 * 1024;
-	else {
-		if (IS_GEN2(devid)) {
-			tile_width = 128;
-			tile_height = 16;
-		}
+	} else if (intel_gen(devid) >= 3) {
+		stride = 8 * 1024;
+	} else if (intel_gen(devid) >= 2) {
+		tile_width = 128;
+		tile_height = 16;
 		stride = 8 * 1024;
+	} else {
+		igt_skip("Unknown Intel chipset, devid=%04x\n", devid);
 	}
 
 	size = stride * tile_height;
-- 
2.20.1

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-04-26 15:00 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-04-26  7:56 [igt-dev] [PATCH i-g-t] i915/gem_tiling_max_stride: Skip if chipset is unknown Chris Wilson
2019-04-26  8:20 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2019-04-26 13:47 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork
2019-04-26 15:00 ` [igt-dev] [PATCH i-g-t] " Ville Syrjälä

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox