From a84fcc1e45d3f6f6dbd29cbc7aea9d34e53c472a Mon Sep 17 00:00:00 2001 From: Suresh Siddha Date: Thu, 19 Jul 2007 21:28:35 +0200 Subject: [PATCH] --- yaml --- r: 61770 b: refs/heads/master c: 969bb4e4032dac67287951d8f6642a3b5119694e h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/kernel/sched.c | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index 0e3207de3015..0475ae790500 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 9439aab8dbc33c2c03c3a19dba267360383ba38c +refs/heads/master: 969bb4e4032dac67287951d8f6642a3b5119694e diff --git a/trunk/kernel/sched.c b/trunk/kernel/sched.c index e36d99d1ddb1..a35a92ff38fd 100644 --- a/trunk/kernel/sched.c +++ b/trunk/kernel/sched.c @@ -2679,6 +2679,7 @@ load_balance_newidle(int this_cpu, struct rq *this_rq, struct sched_domain *sd) unsigned long imbalance; int nr_moved = 0; int sd_idle = 0; + int all_pinned = 0; cpumask_t cpus = CPU_MASK_ALL; /* @@ -2717,10 +2718,11 @@ load_balance_newidle(int this_cpu, struct rq *this_rq, struct sched_domain *sd) double_lock_balance(this_rq, busiest); nr_moved = move_tasks(this_rq, this_cpu, busiest, minus_1_or_zero(busiest->nr_running), - imbalance, sd, CPU_NEWLY_IDLE, NULL); + imbalance, sd, CPU_NEWLY_IDLE, + &all_pinned); spin_unlock(&busiest->lock); - if (!nr_moved) { + if (unlikely(all_pinned)) { cpu_clear(cpu_of(busiest), cpus); if (!cpus_empty(cpus)) goto redo;