[PATCH v1] drm/i915/selftest: Log throttle reasons on failure

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Log throttle reasons on selftest failure which will be useful for
debugging.

Signed-off-by: Raag Jadav <raag.jadav@xxxxxxxxx>
---
 drivers/gpu/drm/i915/gt/selftest_rps.c | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/i915/gt/selftest_rps.c b/drivers/gpu/drm/i915/gt/selftest_rps.c
index dcef8d498919..1e0e59bc69b6 100644
--- a/drivers/gpu/drm/i915/gt/selftest_rps.c
+++ b/drivers/gpu/drm/i915/gt/selftest_rps.c
@@ -478,8 +478,11 @@ int live_rps_control(void *arg)
 			min, max, ktime_to_ns(min_dt), ktime_to_ns(max_dt));
 
 		if (limit == rps->min_freq) {
-			pr_err("%s: GPU throttled to minimum!\n",
-			       engine->name);
+			u32 throttle = intel_uncore_read(gt->uncore,
+							 intel_gt_perf_limit_reasons_reg(gt));
+
+			pr_err("%s: GPU throttled to minimum frequency with reasons 0x%08x\n",
+			       engine->name, throttle & GT0_PERF_LIMIT_REASONS_MASK);
 			show_pstate_limits(rps);
 			err = -ENODEV;
 			break;
-- 
2.34.1




[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux