diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2007-11-06 21:48:45 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2007-11-06 21:48:45 +0000 |
commit | 046f0556dc61807b9d6a98972d4d673a623edeae (patch) | |
tree | 0e9ca399627065e5e372046642a4e185db8113da /sys | |
parent | c246966ebb010927755054fcc18047652d649fb3 (diff) |
Keep a pending software interrupts mask per processor, instead of having it
global; and only schedule software interrupts on the currently running cpu.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/m88k/include/cpu.h | 6 | ||||
-rw-r--r-- | sys/arch/m88k/m88k/m88k_machdep.c | 8 |
2 files changed, 7 insertions, 7 deletions
diff --git a/sys/arch/m88k/include/cpu.h b/sys/arch/m88k/include/cpu.h index b6b5e6d479a..5c6b24c7726 100644 --- a/sys/arch/m88k/include/cpu.h +++ b/sys/arch/m88k/include/cpu.h @@ -1,4 +1,4 @@ -/* $OpenBSD: cpu.h,v 1.28 2007/11/06 21:42:56 miod Exp $ */ +/* $OpenBSD: cpu.h,v 1.29 2007/11/06 21:48:42 miod Exp $ */ /* * Copyright (c) 1996 Nivas Madhur * Copyright (c) 1992, 1993 @@ -112,6 +112,7 @@ struct cpu_info { #define CI_IPI_HARDCLOCK 0x00000002 #define CI_IPI_STATCLOCK 0x00000004 #define CI_IPI_DDB 0x00000008 + int ci_softintr; /* pending soft interrupts */ }; extern cpuid_t master_cpu; @@ -201,8 +202,7 @@ struct clockframe { #define SIR_NET 0x01 #define SIR_CLOCK 0x02 -extern unsigned int ssir; -#define setsoftint(x) atomic_setbits_int(&ssir, x) +#define setsoftint(x) atomic_setbits_int(&curcpu()->ci_softintr, x) #define setsoftnet() setsoftint(SIR_NET) #define setsoftclock() setsoftint(SIR_CLOCK) diff --git a/sys/arch/m88k/m88k/m88k_machdep.c b/sys/arch/m88k/m88k/m88k_machdep.c index fbd05d1e5dd..01469ce3f8e 100644 --- a/sys/arch/m88k/m88k/m88k_machdep.c +++ b/sys/arch/m88k/m88k/m88k_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: m88k_machdep.c,v 1.26 2007/11/06 21:42:56 miod Exp $ */ +/* $OpenBSD: m88k_machdep.c,v 1.27 2007/11/06 21:48:44 miod Exp $ */ /* * Copyright (c) 1998, 1999, 2000, 2001 Steve Murphree, Jr. * Copyright (c) 1996 Nivas Madhur @@ -312,18 +312,18 @@ signotify(struct proc *p) * Soft interrupt interface */ -unsigned int ssir; int netisr; void dosoftint() { + int *ssir = &curcpu()->ci_softintr; int sir, n; - if ((sir = ssir) == 0) + if ((sir = *ssir) == 0) return; - atomic_clearbits_int(&ssir, sir); + atomic_clearbits_int(ssir, sir); uvmexp.softs++; if (ISSET(sir, SIR_NET)) { |