Re: [PATCH 01/10] drm/sched: move calling drm_sched_entity_select_rq

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

 



Can you please remind me of the use case that requires this ? I browsed through
related mails in the past but haven't found when is that needed. For amdgpu
drm_sched_job_init and drm_sched_job_arm are called together and amdgpu
is the only one who supports modifying entity priority on the fly as far as i see.

Andrey

On 2022-07-14 06:38, Christian König wrote:
We already discussed that the call to drm_sched_entity_select_rq() needs
to move to drm_sched_job_arm() to be able to set a new scheduler list
between _init() and _arm(). This was just not applied for some reason.

Signed-off-by: Christian König <christian.koenig@xxxxxxx>
CC: Andrey Grodzovsky <andrey.grodzovsky@xxxxxxx>
CC: dri-devel@xxxxxxxxxxxxxxxxxxxxx
---
  drivers/gpu/drm/scheduler/sched_main.c | 3 +--
  1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/scheduler/sched_main.c b/drivers/gpu/drm/scheduler/sched_main.c
index 68317d3a7a27..e0ab14e0fb6b 100644
--- a/drivers/gpu/drm/scheduler/sched_main.c
+++ b/drivers/gpu/drm/scheduler/sched_main.c
@@ -592,7 +592,6 @@ int drm_sched_job_init(struct drm_sched_job *job,
  		       struct drm_sched_entity *entity,
  		       void *owner)
  {
-	drm_sched_entity_select_rq(entity);
  	if (!entity->rq)
  		return -ENOENT;
@@ -628,7 +627,7 @@ void drm_sched_job_arm(struct drm_sched_job *job)
  	struct drm_sched_entity *entity = job->entity;
BUG_ON(!entity);
-
+	drm_sched_entity_select_rq(entity);
  	sched = entity->rq->sched;
job->sched = sched;



[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux