diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2007-05-14 16:59:44 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2007-05-14 16:59:44 +0000 |
commit | 324e84af407cac6fe6c7ee0d3fed906b9c4e3128 (patch) | |
tree | 846249d60fa52ff896bbc7f2c1ccb01299450752 | |
parent | c474ef3bf43a070b0491107b1089272a1d83350a (diff) |
Hold kernel_lock when processing interrupts at a level under IPL_SCHED, as
done on 188, for MULTIPROCESSOR kernels.
-rw-r--r-- | sys/arch/mvme88k/mvme88k/m187_machdep.c | 12 | ||||
-rw-r--r-- | sys/arch/mvme88k/mvme88k/m197_machdep.c | 12 |
2 files changed, 22 insertions, 2 deletions
diff --git a/sys/arch/mvme88k/mvme88k/m187_machdep.c b/sys/arch/mvme88k/mvme88k/m187_machdep.c index ac28fd07c08..b61990d34d9 100644 --- a/sys/arch/mvme88k/mvme88k/m187_machdep.c +++ b/sys/arch/mvme88k/mvme88k/m187_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: m187_machdep.c,v 1.14 2007/05/12 20:02:14 miod Exp $ */ +/* $OpenBSD: m187_machdep.c,v 1.15 2007/05/14 16:59:43 miod Exp $ */ /* * Copyright (c) 1998, 1999, 2000, 2001 Steve Murphree, Jr. * Copyright (c) 1996 Nivas Madhur @@ -126,6 +126,11 @@ m187_ext_int(u_int v, struct trapframe *eframe) ivec = M187_IACK + (level << 2) + 0x03; vec = *(volatile u_int8_t *)ivec; +#ifdef MULTIPROCESSOR + if (eframe->tf_mask < IPL_SCHED) + __mp_lock(&kernel_lock); +#endif + uvmexp.intrs++; /* block interrupts at level or lower */ @@ -184,6 +189,11 @@ m187_ext_int(u_int v, struct trapframe *eframe) * be restored later. */ set_psr(get_psr() | PSR_IND); + +#ifdef MULTIPROCESSOR + if (eframe->tf_mask < IPL_SCHED) + __mp_unlock(&kernel_lock); +#endif } u_int diff --git a/sys/arch/mvme88k/mvme88k/m197_machdep.c b/sys/arch/mvme88k/mvme88k/m197_machdep.c index c6e33c96362..671b4a43eea 100644 --- a/sys/arch/mvme88k/mvme88k/m197_machdep.c +++ b/sys/arch/mvme88k/mvme88k/m197_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: m197_machdep.c,v 1.13 2007/05/12 20:02:14 miod Exp $ */ +/* $OpenBSD: m197_machdep.c,v 1.14 2007/05/14 16:59:43 miod Exp $ */ /* * Copyright (c) 1998, 1999, 2000, 2001 Steve Murphree, Jr. * Copyright (c) 1996 Nivas Madhur @@ -171,6 +171,11 @@ m197_ext_int(u_int v, struct trapframe *eframe) vec = *(volatile u_int8_t *)ivec; } +#ifdef MULTIPROCESSOR + if (eframe->tf_mask < IPL_SCHED) + __mp_lock(&kernel_lock); +#endif + uvmexp.intrs++; if (v != T_NON_MASK || cold == 0) { @@ -225,6 +230,11 @@ m197_ext_int(u_int v, struct trapframe *eframe) */ set_psr(get_psr() | PSR_IND); } + +#ifdef MULTIPROCESSOR + if (eframe->tf_mask < IPL_SCHED) + __mp_unlock(&kernel_lock); +#endif } u_int |