[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20140729152631.GW12054@laptop.lan>
Date: Tue, 29 Jul 2014 17:26:31 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: riel@...hat.com
Cc: linux-kernel@...r.kernel.org, vincent.guittot@...aro.org,
mikey@...ling.org, mingo@...nel.org, jhladky@...hat.com,
ktkhai@...allels.com, tim.c.chen@...ux.intel.com,
nicolas.pitre@...aro.org
Subject: Re: [PATCH 1/2] sched: fix and clean up calculate_imbalance
On Tue, Jul 29, 2014 at 04:53:08PM +0200, Peter Zijlstra wrote:
> Ah, wait, I think I see why you want that gone. I was only expecting a
> correction fix wrt changing pick_busiest(), not also behaviour changes.
---
Subject: sched,fair: Make calculate_imbalance() independent
From: Peter Zijlstra <peterz@...radead.org>
Date: Tue Jul 29 17:00:21 CEST 2014
Rik noticed that calculate_imbalance() relies on
update_sd_pick_busiest() to guarantee that busiest->sum_nr_running >
busiest->group_capacity_factor.
Break this implicit assumption (with the intent of not providing it
anymore) by having calculat_imbalance() verify it and not rely on
others.
Reported-by: Rik van Riel <riel@...hat.com>
Signed-off-by: Peter Zijlstra <peterz@...radead.org>
---
kernel/sched/fair.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -6248,7 +6248,7 @@ static inline void calculate_imbalance(s
return fix_small_imbalance(env, sds);
}
- if (!busiest->group_imb) {
+ if (busiest->sum_nr_running > busiest->group_capacity_factor) {
/*
* Don't want to pull so many tasks that a group would go idle.
* Except of course for the group_imb case, since then we might
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists