]> git.hungrycats.org Git - linux/commit
[PATCH] debug sched domains before attach
authorNick Piggin <nickpiggin@yahoo.com.au>
Sat, 8 Jan 2005 05:54:31 +0000 (21:54 -0800)
committerLinus Torvalds <torvalds@evo.osdl.org>
Sat, 8 Jan 2005 05:54:31 +0000 (21:54 -0800)
commit7f257c1bd4ee84c4d28c3a64faa7d4480c2b2e0e
tree84352f1f772a6ca2d09d3e58dcd500e220f7a162
parentc919160eb480660edf9719ee3aa443c1fd841be0
[PATCH] debug sched domains before attach

Change the sched-domain debug routine to be called on a per-CPU basis, and
executed before the domain is actually attached to the CPU.  Previously, all
CPUs would have their new domains attached, and then the debug routine would
loop over all of them.

This has two advantages: First, there is no longer any theoretical races: we
are running the debug routine on a domain that isn't yet active, and should
have no racing access from another CPU.  Second, if there is a problem with a
domain, the validator will have a better chance to catch the error and print a
diagnostic _before_ the domain is attached, which may take down the system.

Also, change reporting of detected error conditions to KERN_ERR instead of
KERN_DEBUG, so they have a better chance of being seen in a hang on boot
situation.

The patch also does an unrelated (and harmless) cleanup in migration_thread().

Signed-off-by: Nick Piggin <nickpiggin@yahoo.com.au>
Acked-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
kernel/sched.c