intel-gfx.lists.freedesktop.org archive mirror
 help / color / mirror / Atom feed
* [Intel-gfx] [PATCH] drm/i915/selftests: Keep rps pinned during time critical tests
@ 2020-05-15 19:46 Chris Wilson
  2020-05-15 20:57 ` [Intel-gfx] ✓ Fi.CI.BAT: success for " Patchwork
  2020-05-16  2:17 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
  0 siblings, 2 replies; 3+ messages in thread
From: Chris Wilson @ 2020-05-15 19:46 UTC (permalink / raw)
  To: intel-gfx; +Cc: Chris Wilson

The timeslice queue tries to complete a round-robin discovery of a deep
and pathological semaphore chain within a certain time limit. It helps
if we can keep RPS pinned during this so that we do not waste time on a
slow GPU.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
---
 drivers/gpu/drm/i915/gt/selftest_lrc.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/gpu/drm/i915/gt/selftest_lrc.c b/drivers/gpu/drm/i915/gt/selftest_lrc.c
index 824f99c4cc7c..9edb0eb02e90 100644
--- a/drivers/gpu/drm/i915/gt/selftest_lrc.c
+++ b/drivers/gpu/drm/i915/gt/selftest_lrc.c
@@ -1197,6 +1197,8 @@ static int live_timeslice_queue(void *arg)
 	if (err)
 		goto err_pin;
 
+	atomic_inc(&gt->rps.num_waiters); /* keep rps pinned */
+	intel_gt_pm_get(gt);
 	for_each_engine(engine, gt, id) {
 		struct i915_sched_attr attr = {
 			.priority = I915_USER_PRIORITY(I915_PRIORITY_MAX),
@@ -1288,6 +1290,8 @@ static int live_timeslice_queue(void *arg)
 		if (err)
 			break;
 	}
+	intel_gt_pm_put(gt);
+	atomic_dec(&gt->rps.num_waiters);
 
 err_pin:
 	i915_vma_unpin(vma);
-- 
2.20.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

end of thread, other threads:[~2020-05-16  2:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-15 19:46 [Intel-gfx] [PATCH] drm/i915/selftests: Keep rps pinned during time critical tests Chris Wilson
2020-05-15 20:57 ` [Intel-gfx] ✓ Fi.CI.BAT: success for " Patchwork
2020-05-16  2:17 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).