summaryrefslogtreecommitdiff
path: root/tests/gem_reloc_overflow.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2017-06-29 17:16:27 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2017-06-29 17:17:43 +0100
commit0aa9fd12a2f25faa9a7625a1896c31b0d257390f (patch)
tree21062add6a4d5af120052adac1f76fa20ba07541 /tests/gem_reloc_overflow.c
parent2fd6adaf2ebdfac4a3091880d047a3feda81db49 (diff)
igt/gem_reloc_overflow: Pass the right invalid presumed_offset
Several tests were passing a presumed_offset that matches the actual offset of the object and so were very suprised when the kernel promptly skipped performing the relocation (as expected). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'tests/gem_reloc_overflow.c')
-rw-r--r--tests/gem_reloc_overflow.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/gem_reloc_overflow.c b/tests/gem_reloc_overflow.c
index 3419e94f..c9d1f207 100644
--- a/tests/gem_reloc_overflow.c
+++ b/tests/gem_reloc_overflow.c
@@ -96,7 +96,7 @@ static void source_offset_tests(int devid, bool reloc_gtt)
single_reloc.target_handle = target_handle();
single_reloc.read_domains = I915_GEM_DOMAIN_RENDER;
single_reloc.write_domain = I915_GEM_DOMAIN_RENDER;
- single_reloc.presumed_offset = 0;
+ single_reloc.presumed_offset = -1;
gem_execbuf(fd, &execbuf);
single_reloc.delta = 1024;
@@ -110,7 +110,7 @@ static void source_offset_tests(int devid, bool reloc_gtt)
single_reloc.target_handle = target_handle();
single_reloc.read_domains = I915_GEM_DOMAIN_RENDER;
single_reloc.write_domain = I915_GEM_DOMAIN_RENDER;
- single_reloc.presumed_offset = 0;
+ single_reloc.presumed_offset = -1;
gem_execbuf(fd, &execbuf);
}
@@ -121,7 +121,7 @@ static void source_offset_tests(int devid, bool reloc_gtt)
single_reloc.target_handle = target_handle();
single_reloc.read_domains = I915_GEM_DOMAIN_RENDER;
single_reloc.write_domain = I915_GEM_DOMAIN_RENDER;
- single_reloc.presumed_offset = 0;
+ single_reloc.presumed_offset = -1;
igt_assert_eq(__gem_execbuf(fd, &execbuf), -EINVAL);
}
@@ -133,7 +133,7 @@ static void source_offset_tests(int devid, bool reloc_gtt)
single_reloc.target_handle = target_handle();
single_reloc.read_domains = I915_GEM_DOMAIN_RENDER;
single_reloc.write_domain = I915_GEM_DOMAIN_RENDER;
- single_reloc.presumed_offset = 0;
+ single_reloc.presumed_offset = -1;
gem_execbuf(fd, &execbuf);
}
@@ -143,7 +143,7 @@ static void source_offset_tests(int devid, bool reloc_gtt)
single_reloc.target_handle = target_handle();
single_reloc.read_domains = I915_GEM_DOMAIN_RENDER;
single_reloc.write_domain = I915_GEM_DOMAIN_RENDER;
- single_reloc.presumed_offset = 0;
+ single_reloc.presumed_offset = -1;
igt_assert_eq(__gem_execbuf(fd, &execbuf), -EINVAL);
}
@@ -153,7 +153,7 @@ static void source_offset_tests(int devid, bool reloc_gtt)
single_reloc.target_handle = target_handle();
single_reloc.read_domains = I915_GEM_DOMAIN_RENDER;
single_reloc.write_domain = I915_GEM_DOMAIN_RENDER;
- single_reloc.presumed_offset = 0;
+ single_reloc.presumed_offset = -1;
igt_assert_eq(__gem_execbuf(fd, &execbuf), -EINVAL);
}
@@ -163,7 +163,7 @@ static void source_offset_tests(int devid, bool reloc_gtt)
single_reloc.target_handle = target_handle();
single_reloc.read_domains = I915_GEM_DOMAIN_RENDER;
single_reloc.write_domain = I915_GEM_DOMAIN_RENDER;
- single_reloc.presumed_offset = 0;
+ single_reloc.presumed_offset = -1;
igt_assert_eq(__gem_execbuf(fd, &execbuf), -EINVAL);
}
}