[igt-dev] [CI i-g-t] tests/perf_pmu: Try to repro GL #6806

Ashutosh Dixit ashutosh.dixit at intel.com
Mon Nov 7 19:50:36 UTC 2022


CI ONLY, PLEASE DON'T REVIEW

Try to repro GL #6806 and see what is really happening there since it could
not be reproduced locally. Also see if the
https://patchwork.freedesktop.org/series/110574/ will fix the issue.

Bug: https://gitlab.freedesktop.org/drm/intel/-/issues/6806
Signed-off-by: Ashutosh Dixit <ashutosh.dixit at intel.com>
---
 tests/i915/perf_pmu.c                 | 5 ++++-
 tests/intel-ci/fast-feedback.testlist | 1 +
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/tests/i915/perf_pmu.c b/tests/i915/perf_pmu.c
index f363db2ba13..bc84b01432e 100644
--- a/tests/i915/perf_pmu.c
+++ b/tests/i915/perf_pmu.c
@@ -1546,7 +1546,7 @@ test_interrupts_sync(int gem_fd)
 static void
 test_frequency(int gem_fd)
 {
-	uint32_t min_freq, max_freq, boost_freq;
+	uint32_t min_freq, max_freq, boost_freq, min_req, max_req;
 	uint64_t val[2], start[2], slept;
 	double min[2], max[2];
 	igt_spin_t *spin;
@@ -1587,6 +1587,7 @@ test_frequency(int gem_fd)
 
 	min[0] = 1e9*(val[0] - start[0]) / slept;
 	min[1] = 1e9*(val[1] - start[1]) / slept;
+	min_req = igt_sysfs_get_u32(sysfs, "gt_cur_freq_mhz");
 
 	igt_spin_free(gem_fd, spin);
 	gem_quiescent_gpu(gem_fd); /* Don't leak busy bo into the next phase */
@@ -1613,6 +1614,7 @@ test_frequency(int gem_fd)
 
 	max[0] = 1e9*(val[0] - start[0]) / slept;
 	max[1] = 1e9*(val[1] - start[1]) / slept;
+	max_req = igt_sysfs_get_u32(sysfs, "gt_cur_freq_mhz");
 
 	igt_spin_free(gem_fd, spin);
 	gem_quiescent_gpu(gem_fd);
@@ -1632,6 +1634,7 @@ test_frequency(int gem_fd)
 		 min[0], min[1]);
 	igt_info("Max frequency: requested %.1f, actual %.1f\n",
 		 max[0], max[1]);
+	igt_info("Sysfs requested: min %d, max %d\n", min_req, max_req);
 
 	assert_within_epsilon(min[0], min_freq, tolerance);
 	/*
diff --git a/tests/intel-ci/fast-feedback.testlist b/tests/intel-ci/fast-feedback.testlist
index f57f8ff3be1..a2bb37fb4ae 100644
--- a/tests/intel-ci/fast-feedback.testlist
+++ b/tests/intel-ci/fast-feedback.testlist
@@ -128,6 +128,7 @@ igt at i915_pm_backlight@basic-brightness
 igt at i915_pm_rpm@basic-pci-d3-state
 igt at i915_pm_rpm@basic-rte
 igt at i915_pm_rps@basic-api
+igt at perf_pmu@frequency
 igt at prime_self_import@basic-llseek-bad
 igt at prime_self_import@basic-llseek-size
 igt at prime_self_import@basic-with_fd_dup
-- 
2.38.0



More information about the igt-dev mailing list