aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorNathan Lynch <nathanl@austin.ibm.com>2004-08-22 22:33:51 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2004-08-22 22:33:51 -0700
commit292ae1292c4f1f7c46a5dd0e67ef9741855d716b (patch)
tree0bf6c42bada201f45bc47d49c4793a8dffb92009 /arch
parent37cfbd3191f15ecb84595c45fb095033fe54bd3a (diff)
downloadhistory-292ae1292c4f1f7c46a5dd0e67ef9741855d716b.tar.gz
[PATCH] ppc64: tweak schedule_timeout in __cpu_die
The current code does schedule_timeout(HZ) when waiting for a cpu to die, which is a bit coarse and tends to limit the "throughput" of my stress tests :) Change the HZ timeout to HZ/5, increase the number of tries to 25 so the overall wait time is similar. In practice, I've never seen the loop need more than two iterations. Signed-off-by: Nathan Lynch <nathanl@austin.ibm.com> Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/ppc64/kernel/smp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/ppc64/kernel/smp.c b/arch/ppc64/kernel/smp.c
index 828cdf36aeec44..b72e964c3a1227 100644
--- a/arch/ppc64/kernel/smp.c
+++ b/arch/ppc64/kernel/smp.c
@@ -271,13 +271,13 @@ void __cpu_die(unsigned int cpu)
int cpu_status;
unsigned int pcpu = get_hard_smp_processor_id(cpu);
- for (tries = 0; tries < 5; tries++) {
+ for (tries = 0; tries < 25; tries++) {
cpu_status = query_cpu_stopped(pcpu);
if (cpu_status == 0)
break;
set_current_state(TASK_UNINTERRUPTIBLE);
- schedule_timeout(HZ);
+ schedule_timeout(HZ/5);
}
if (cpu_status != 0) {
printk("Querying DEAD? cpu %i (%i) shows %i\n",