sched: Change NODE sched_domain group creation
authorPeter Zijlstra <a.p.zijlstra@chello.nl>
Thu, 7 Apr 2011 12:09:45 +0000 (14:09 +0200)
committerIngo Molnar <mingo@elte.hu>
Mon, 11 Apr 2011 10:58:17 +0000 (12:58 +0200)
commitcd4ea6ae3982f6861da3b510e69cbc194f331d83
tree7ca7e19bf9be55102768f7c1ab2bd76643e6524b
parenta06dadbec5c5df0bf3a35f33616f67d10ca9ba28
sched: Change NODE sched_domain group creation

The NODE sched_domain is 'special' in that it allocates sched_groups
per CPU, instead of sharing the sched_groups between all CPUs.

While this might have some benefits on large NUMA and avoid remote
memory accesses when iterating the sched_groups, this does break
current code that assumes sched_groups are shared between all
sched_domains (since the dynamic cpu_power patches).

So refactor the NODE groups to behave like all other groups.

(The ALLNODES domain again shared its groups across the CPUs for some
reason).

If someone does measure a performance decrease due to this change we
need to revisit this and come up with another way to have both dynamic
cpu_power and NUMA work nice together.

Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Nick Piggin <npiggin@kernel.dk>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Link: http://lkml.kernel.org/r/20110407122941.978111700@chello.nl
Signed-off-by: Ingo Molnar <mingo@elte.hu>
kernel/sched.c