[PATCH 3/4] drm/i915/execlists: Tweak priority hint to use last port if set

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

 



We use the priority hint to decide if it is worth resubmitting in order
to replace the currently contexts with new requests. If we have left a
port open, the hint should be taken from the top of the queue (as that
is the highest priority request that should be sent next but for
whatever reason could not be). However, if we have filled the second
submission port, that represents the lowest priority of the currently
executing requests and we do not need to kick the submission tasklet
unless we have something that is of higher priority.  This just removes a
few useless kicks and queuing of the submission tasklet.

Signed-off-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
---
 drivers/gpu/drm/i915/gt/intel_lrc.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/gpu/drm/i915/gt/intel_lrc.c b/drivers/gpu/drm/i915/gt/intel_lrc.c
index 3ab2b7e18351..c48901fd17e9 100644
--- a/drivers/gpu/drm/i915/gt/intel_lrc.c
+++ b/drivers/gpu/drm/i915/gt/intel_lrc.c
@@ -1983,10 +1983,8 @@ static void execlists_dequeue(struct intel_engine_cs *engine)
 	 * request triggering preemption on the next dequeue (or subsequent
 	 * interrupt for secondary ports).
 	 */
-	execlists->queue_priority_hint = queue_prio(execlists);
-	GEM_TRACE("%s: queue_priority_hint:%d, submit:%s\n",
-		  engine->name, execlists->queue_priority_hint,
-		  yesno(submit));
+	execlists->queue_priority_hint =
+		port == last_port ? rq_prio(last) : queue_prio(execlists);
 
 	if (submit) {
 		*port = execlists_schedule_in(last, port - execlists->pending);
-- 
2.24.0

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




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

  Powered by Linux