diff options
author | 2007-04-05 17:31:47 +0000 | |
---|---|---|
committer | 2007-04-05 17:31:47 +0000 | |
commit | 816847c8fb53d98ee4b71ebb51c4cb8405901cb5 (patch) | |
tree | 2ff454cf6d355ca7c5be20a90354b51ee6c5eb03 | |
parent | We also don't need the microcode builder anymore. (diff) | |
download | wireguard-openbsd-816847c8fb53d98ee4b71ebb51c4cb8405901cb5.tar.xz wireguard-openbsd-816847c8fb53d98ee4b71ebb51c4cb8405901cb5.zip |
splx() does not need to return a value.
-rw-r--r-- | sys/arch/vax/include/intr.h | 11 | ||||
-rw-r--r-- | sys/arch/vax/vax/db_machdep.c | 4 |
2 files changed, 9 insertions, 6 deletions
diff --git a/sys/arch/vax/include/intr.h b/sys/arch/vax/include/intr.h index 6a7ce4d4094..8cd3c6eb73e 100644 --- a/sys/arch/vax/include/intr.h +++ b/sys/arch/vax/include/intr.h @@ -1,4 +1,4 @@ -/* $OpenBSD: intr.h,v 1.5 2006/06/02 17:39:58 miod Exp $ */ +/* $OpenBSD: intr.h,v 1.6 2007/04/05 17:31:47 miod Exp $ */ /* $NetBSD: intr.h,v 1.1 1998/08/18 23:55:00 matt Exp $ */ /* @@ -56,7 +56,7 @@ #define IST_LEVEL 3 /* level-triggered */ #ifndef lint -#define splx(reg) \ +#define _splset(reg) \ ({ \ register int val; \ __asm __volatile ("mfpr $0x12,%0;mtpr %1,$0x12" \ @@ -78,9 +78,12 @@ } \ val; \ }) + +#define splx(reg) \ + __asm __volatile ("mtpr %0,$0x12" : : "g" (reg)) #endif -#define spl0() splx(IPL_NONE) +#define spl0() _splset(IPL_NONE) #define splsoftclock() _splraise(IPL_SOFTCLOCK) #define splsoftnet() _splraise(IPL_SOFTNET) #define splbio() _splraise(IPL_BIO) @@ -89,7 +92,7 @@ #define splvm() _splraise(IPL_VM) #define splclock() _splraise(IPL_CLOCK) #define splstatclock() _splraise(IPL_STATCLOCK) -#define splhigh() splx(IPL_HIGH) +#define splhigh() _splset(IPL_HIGH) /* These are better to use when playing with VAX buses */ #define spl4() _splraise(0x14) diff --git a/sys/arch/vax/vax/db_machdep.c b/sys/arch/vax/vax/db_machdep.c index a4a325e4476..a535110293a 100644 --- a/sys/arch/vax/vax/db_machdep.c +++ b/sys/arch/vax/vax/db_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: db_machdep.c,v 1.16 2006/07/14 15:22:55 miod Exp $ */ +/* $OpenBSD: db_machdep.c,v 1.17 2007/04/05 17:31:49 miod Exp $ */ /* $NetBSD: db_machdep.c,v 1.17 1999/06/20 00:58:23 ragge Exp $ */ /* @@ -199,7 +199,7 @@ db_write_bytes(addr, size, data) void Debugger() { - splsave = splx(0xe); + splsave = _splset(0xe); mtpr(0xf, PR_SIRR); /* beg for debugger */ splx(splsave); } |