Skip to content

Commit 9ee1cda

Browse files
msrasmussenIngo Molnar
authored andcommitted
sched/core: Enable SD_BALANCE_WAKE for asymmetric capacity systems
A domain with the SD_ASYM_CPUCAPACITY flag set indicate that sched_groups at this level and below do not include CPUs of all capacities available (e.g. group containing little-only or big-only CPUs in big.LITTLE systems). It is therefore necessary to put in more effort in finding an appropriate CPU at task wake-up by enabling balancing at wake-up (SD_BALANCE_WAKE) on all lower (child) levels. Signed-off-by: Morten Rasmussen <[email protected]> Signed-off-by: Peter Zijlstra (Intel) <[email protected]> Cc: Linus Torvalds <[email protected]> Cc: Mike Galbraith <[email protected]> Cc: Peter Zijlstra <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Cc: [email protected] Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Ingo Molnar <[email protected]>
1 parent 3676b13 commit 9ee1cda

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

kernel/sched/core.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6444,6 +6444,13 @@ sd_init(struct sched_domain_topology_level *tl,
64446444
* Convert topological properties into behaviour.
64456445
*/
64466446

6447+
if (sd->flags & SD_ASYM_CPUCAPACITY) {
6448+
struct sched_domain *t = sd;
6449+
6450+
for_each_lower_domain(t)
6451+
t->flags |= SD_BALANCE_WAKE;
6452+
}
6453+
64476454
if (sd->flags & SD_SHARE_CPUCAPACITY) {
64486455
sd->flags |= SD_PREFER_SIBLING;
64496456
sd->imbalance_pct = 110;

0 commit comments

Comments
 (0)