[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1568878421-12301-9-git-send-email-vincent.guittot@linaro.org>
Date: Thu, 19 Sep 2019 09:33:39 +0200
From: Vincent Guittot <vincent.guittot@...aro.org>
To: linux-kernel@...r.kernel.org, mingo@...hat.com,
peterz@...radead.org
Cc: pauld@...hat.com, valentin.schneider@....com,
srikar@...ux.vnet.ibm.com, quentin.perret@....com,
dietmar.eggemann@....com, Morten.Rasmussen@....com,
hdanton@...a.com, Vincent Guittot <vincent.guittot@...aro.org>
Subject: [PATCH v3 08/10] sched/fair: use utilization to select misfit task
utilization is used to detect a misfit task but the load is then used to
select the task on the CPU which can lead to select a small task with
high weight instead of the task that triggered the misfit migration.
Signed-off-by: Vincent Guittot <vincent.guittot@...aro.org>
Acked-by: Valentin Schneider <valentin.schneider@....com>
---
kernel/sched/fair.c | 10 ++--------
1 file changed, 2 insertions(+), 8 deletions(-)
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index a7c8ee6..acca869 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -7429,14 +7429,8 @@ static int detach_tasks(struct lb_env *env)
break;
case migrate_misfit:
- load = task_h_load(p);
-
- /*
- * utilization of misfit task might decrease a bit
- * since it has been recorded. Be conservative in the
- * condition.
- */
- if (load < env->imbalance)
+ /* This is not a misfit task */
+ if (task_fits_capacity(p, capacity_of(env->src_cpu)))
goto next;
env->imbalance = 0;
--
2.7.4
Powered by blists - more mailing lists