Igt-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 1/2] tests/intel/xe_pm_residency: convert all tests to dynamic subtests
@ 2024-07-25 17:23 Matthew Brost
  2024-07-25 17:23 ` [PATCH v3 2/2] tests/intel/xe_vm: Test zero number of VM binds Matthew Brost
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Matthew Brost @ 2024-07-25 17:23 UTC (permalink / raw)
  To: igt-dev; +Cc: kamil.konieczny

From: Riana Tauro <riana.tauro@intel.com>

Convert all tests to dynamic subtests to identify which GT
the tests are running on.

No functional changes

Signed-off-by: Riana Tauro <riana.tauro@intel.com>
Reviewed-by: Anshuman Gupta <anshuman.gupta@intel.com>
Signed-off-by: Anshuman Gupta <anshuman.gupta@intel.com>
---
 tests/intel/xe_pm_residency.c | 31 ++++++++++++++++++++-----------
 1 file changed, 20 insertions(+), 11 deletions(-)

diff --git a/tests/intel/xe_pm_residency.c b/tests/intel/xe_pm_residency.c
index 367b1027c6..51735d8874 100644
--- a/tests/intel/xe_pm_residency.c
+++ b/tests/intel/xe_pm_residency.c
@@ -233,8 +233,8 @@ static void idle_residency_on_exec(int fd, struct drm_xe_engine_class_instance *
 	unsigned long end, start;
 	unsigned long elapsed_ms, residency_end, residency_start;
 
-	igt_debug("Running on %s:%d\n",
-		  xe_engine_class_string(hwe->engine_class), hwe->engine_instance);
+	igt_info("Running on %s:%d\n",
+		 xe_engine_class_string(hwe->engine_class), hwe->engine_instance);
 	done = mmap(0, 4096, PROT_WRITE, MAP_SHARED | MAP_ANON, -1, 0);
 	igt_assert(done != MAP_FAILED);
 	memset(done, 0, 4096);
@@ -321,35 +321,44 @@ igt_main
 	}
 
 	igt_describe("Validate GT C6 on idle");
-	igt_subtest("gt-c6-on-idle")
+	igt_subtest_with_dynamic("gt-c6-on-idle") {
 		xe_for_each_gt(fd, gt)
-			igt_assert_f(igt_wait(xe_is_gt_in_c6(fd, gt), 1000, 1), "GT %d not in C6\n", gt);
+			igt_dynamic_f("gt%u", gt)
+				igt_assert_f(igt_wait(xe_is_gt_in_c6(fd, gt), 1000, 1),
+					     "GT %d not in C6\n", gt);
+	}
 
 	igt_describe("Validate idle residency measured over suspend cycle is within the tolerance");
-	igt_subtest("gt-c6-freeze") {
+	igt_subtest_with_dynamic("gt-c6-freeze") {
 		if (xe_has_vram(fd)) {
 			igt_device_get_pci_slot_name(fd, pci_slot_name);
 			igt_pm_get_d3cold_allowed(pci_slot_name, &d3cold_allowed);
 			igt_pm_set_d3cold_allowed(pci_slot_name, 0);
 		}
 		xe_for_each_gt(fd, gt)
-			test_idle_residency(fd, gt, TEST_S2IDLE);
+			igt_dynamic_f("gt%u", gt)
+				test_idle_residency(fd, gt, TEST_S2IDLE);
 
 		if (xe_has_vram(fd))
 			igt_pm_set_d3cold_allowed(pci_slot_name, d3cold_allowed);
 	}
 
 	igt_describe("Validate idle residency measured over a time interval is within the tolerance");
-	igt_subtest("idle-residency")
+	igt_subtest_with_dynamic("idle-residency") {
 		xe_for_each_gt(fd, gt)
-			test_idle_residency(fd, gt, TEST_IDLE);
+			igt_dynamic_f("gt%u", gt)
+				test_idle_residency(fd, gt, TEST_IDLE);
+	}
 
 	igt_describe("Validate idle residency on exec");
-	igt_subtest("idle-residency-on-exec") {
+	igt_subtest_with_dynamic("idle-residency-on-exec") {
 		xe_for_each_gt(fd, gt) {
 			xe_for_each_engine(fd, hwe) {
-				if (gt == hwe->gt_id && !hwe->engine_instance)
-					idle_residency_on_exec(fd, hwe);
+				if (gt == hwe->gt_id && !hwe->engine_instance) {
+					igt_dynamic_f("gt%u-engine-%s", gt,
+						      xe_engine_class_string(hwe->engine_class))
+						idle_residency_on_exec(fd, hwe);
+				}
 			}
 		}
 	}
-- 
2.34.1


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

end of thread, other threads:[~2024-07-26  0:09 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-25 17:23 [PATCH v3 1/2] tests/intel/xe_pm_residency: convert all tests to dynamic subtests Matthew Brost
2024-07-25 17:23 ` [PATCH v3 2/2] tests/intel/xe_vm: Test zero number of VM binds Matthew Brost
2024-07-25 18:42 ` ✗ Fi.CI.BAT: failure for series starting with [v3,1/2] tests/intel/xe_pm_residency: convert all tests to dynamic subtests Patchwork
2024-07-25 18:47 ` ✓ CI.xeBAT: success " Patchwork
2024-07-26  0:09 ` ✗ CI.xeFULL: failure " Patchwork

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