diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2014-02-03 18:42:06 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2014-02-03 18:42:06 +0000 |
commit | d5718393295115a87df071eb1345c051d29683f3 (patch) | |
tree | 97d7843ba17b9aad680b9c5f0e05d9b91ac7e4fc /sys/arch/alpha | |
parent | 2d26e55ecbddf46977d54b2304cb9d5759f7d431 (diff) |
Make sure sched_init_cpu() on the secondary processors is invoked with the
kernel lock held.
Diffstat (limited to 'sys/arch/alpha')
-rw-r--r-- | sys/arch/alpha/alpha/cpu.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/arch/alpha/alpha/cpu.c b/sys/arch/alpha/alpha/cpu.c index e94ecf16994..da4742e1892 100644 --- a/sys/arch/alpha/alpha/cpu.c +++ b/sys/arch/alpha/alpha/cpu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cpu.c,v 1.33 2014/02/01 21:17:32 miod Exp $ */ +/* $OpenBSD: cpu.c,v 1.34 2014/02/03 18:42:05 miod Exp $ */ /* $NetBSD: cpu.c,v 1.44 2000/05/23 05:12:53 thorpej Exp $ */ /*- @@ -602,10 +602,12 @@ cpu_hatch(struct cpu_info *ci) ALPHA_TBIA(); alpha_pal_imb(); + KERNEL_LOCK(); sched_init_cpu(ci); nanouptime(&ci->ci_schedstate.spc_runtime); ci->ci_curproc = ci->ci_fpcurproc = NULL; ci->ci_randseed = (arc4random() & 0x7fffffff) + 1; + KERNEL_UNLOCK(); (void) alpha_pal_swpipl(ALPHA_PSL_IPL_0); SCHED_LOCK(s); |