summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2019-04-26 08:54:08 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2019-04-26 16:05:32 +0100
commitcaed251990f35bfe45368f803980071a73e36315 (patch)
treecaeb7cf8bee00d993cbfa37f99952cf8a774b5fb
parent1184e5778ac3ffd8caf3f4d5b9e2b30a736d64d7 (diff)
i915/gem_tiling_max_stride: Skip if chipset is unknown
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> Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
-rw-r--r--tests/i915/gem_tiling_max_stride.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/tests/i915/gem_tiling_max_stride.c b/tests/i915/gem_tiling_max_stride.c
index a6f97a91..0e99d979 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;