diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2007-04-05 17:31:50 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2007-04-05 17:31:50 +0000 |
commit | a2d42fbc3f1466444ef3d0e68f4d166373f0616a (patch) | |
tree | a891e6d629e6fb12e4d4e453175dc9bb3b91f7f1 /sys/arch/vax/include/intr.h | |
parent | d9a4c999176d4ebc12b88ac88f0dd165508d0850 (diff) |
splx() does not need to return a value.
Diffstat (limited to 'sys/arch/vax/include/intr.h')
-rw-r--r-- | sys/arch/vax/include/intr.h | 11 |
1 files changed, 7 insertions, 4 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) |