Commit cfec4ab5 authored by Nick Piggin's avatar Nick Piggin Committed by Linus Torvalds

[PATCH] sched: find_busiest_group cleanup

Cleanup find_busiest_group a bit.  New sched-domains code means we can't have
groups without a CPU.
Signed-off-by: default avatarNick Piggin <nickpiggin@yahoo.com.au>
Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
parent 9ef1a7bf
......@@ -1766,7 +1766,7 @@ find_busiest_group(struct sched_domain *sd, int this_cpu,
do {
unsigned long load;
int local_group;
int i, nr_cpus = 0;
int i;
local_group = cpu_isset(this_cpu, group->cpumask);
......@@ -1780,13 +1780,9 @@ find_busiest_group(struct sched_domain *sd, int this_cpu,
else
load = source_load(i);
nr_cpus++;
avg_load += load;
}
if (!nr_cpus)
goto nextgroup;
total_load += avg_load;
total_pwr += group->cpu_power;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment