Re: [PATCH] drm/scheduler: avoid redundant shifting of the entity v2

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

 



Am 21.08.2018 um 15:29 schrieb Nayan Deshmukh:
do not remove entity from the rq if the current rq is from
the least loaded scheduler.

Signed-off-by: Nayan Deshmukh <nayan26deshmukh@xxxxxxxxx>

Reviewed and pushed into our internal repo.

Thanks,
Christian.

---
  drivers/gpu/drm/scheduler/sched_entity.c | 3 +++
  1 file changed, 3 insertions(+)

diff --git a/drivers/gpu/drm/scheduler/sched_entity.c b/drivers/gpu/drm/scheduler/sched_entity.c
index 1416edb2642a..a51c7654cc78 100644
--- a/drivers/gpu/drm/scheduler/sched_entity.c
+++ b/drivers/gpu/drm/scheduler/sched_entity.c
@@ -472,6 +472,9 @@ void drm_sched_entity_select_rq(struct drm_sched_entity *entity)
  		return;
rq = drm_sched_entity_get_free_sched(entity);
+	if (rq == entity->rq)
+		return;
+
  	spin_lock(&entity->rq_lock);
  	drm_sched_rq_remove_entity(entity->rq, entity);
  	entity->rq = rq;

_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/dri-devel




[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