[igt-dev] [i-g-t, v2] test/i915/gem_exec_reloc: check reloc support in GEM

Tejas Upadhyay tejaskumarx.surendrakumar.upadhyay at intel.com
Tue Mar 16 11:04:34 UTC 2021


i915 kernel driver is dropping reloc support gen12+. This change
will check reloc support in respective platform before executing
gem_exec_reloc in IGT.

Changes since V1 :
	- Adjusted for gem_has_relocations(i915)

Ref : https://patchwork.kernel.org/project/dri-devel/patch/20210311162606.1045592-1-jason@jlekstrand.net/

Cc: Maarten Lankhorst<maarten.lankhorst at intel.com>
Signed-off-by: Tejas Upadhyay <tejaskumarx.surendrakumar.upadhyay at intel.com>
---
 tests/i915/gem_exec_reloc.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/tests/i915/gem_exec_reloc.c b/tests/i915/gem_exec_reloc.c
index 8d52960b..a897cc67 100644
--- a/tests/i915/gem_exec_reloc.c
+++ b/tests/i915/gem_exec_reloc.c
@@ -1478,6 +1478,8 @@ igt_main
 	igt_fixture {
 		fd = drm_open_driver_master(DRIVER_INTEL);
 		igt_require_gem(fd);
+		/* Check if relocations supported by platform */
+		igt_require(gem_has_relocations(fd));
 	}
 
 	for (f = flags; f->name; f++) {
-- 
2.30.0



More information about the igt-dev mailing list