[PATCH v2 i-g-t 3/3] tests/intel/xe_pm_residency: Skip test if 'gtidle' node is missing

Marcin Bernatowicz marcin.bernatowicz at linux.intel.com
Thu Aug 1 14:38:48 UTC 2024


Add an igt_require check for 'gtidle' node to skip residency
tests on VF devices where this node is not present, preventing
test failure.

v2: Use "node" instead of "attribute" for more accuracy

Signed-off-by: Marcin Bernatowicz <marcin.bernatowicz at linux.intel.com>
Reviewed-by: Jonathan Cavitt <jonathan.cavitt at intel.com>
---
 tests/intel/xe_pm_residency.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/tests/intel/xe_pm_residency.c b/tests/intel/xe_pm_residency.c
index 51735d887..9fec3b41a 100644
--- a/tests/intel/xe_pm_residency.c
+++ b/tests/intel/xe_pm_residency.c
@@ -317,7 +317,9 @@ igt_main
 
 	igt_fixture {
 		fd = drm_open_driver(DRIVER_XE);
+
 		igt_require(!IS_PONTEVECCHIO(xe_dev_id(fd)));
+		igt_require(xe_sysfs_gt_has_node(fd, 0, "gtidle"));
 	}
 
 	igt_describe("Validate GT C6 on idle");
-- 
2.31.1



More information about the igt-dev mailing list