1 /* $NetBSD: psl.h,v 1.16 2001/01/14 02:00:38 thorpej Exp $ */ 2 3 #ifndef _MACHINE_PSL_H_ 4 #define _MACHINE_PSL_H_ 5 6 #include <m68k/psl.h> 7 8 #if defined(_KERNEL) && !defined(_LOCORE) 9 10 #define spl0() _spl0() /* we have real software interrupts */ 11 12 #define splnone() spl0() 13 #define spllowersoftclock() spl1() 14 15 #define splsoftclock() splraise1() 16 #define splsoftnet() splraise1() 17 #define splbio() splraise3() 18 #define splnet() splraise3() 19 20 /* 21 * splserial hack, idea by Jason Thorpe. 22 * drivers which need it (at the present only the coms) raise the variable to 23 * their serial interrupt level. 24 * 25 * serialspl is statically initialized in machdep.c at the moment; should 26 * be some driver independent file. 27 * 28 * XXX should serialspl be volatile? I think not; it is intended to be set only 29 * during xxx_attach() time, and will be used only later. 30 * -is 31 */ 32 33 extern u_int16_t amiga_serialspl; 34 #define splserial() _splraise(amiga_serialspl) 35 #define spltty() splraise4() 36 #define splimp() spltty() /* XXX for the full story, see i386 */ 37 #define splvm() splimp() 38 39 #ifndef LEV6_DEFER 40 #define splclock() splraise6() 41 #define splstatclock() splraise6() 42 #define splhigh() spl7() 43 #define splsched() spl7() 44 #define spllock() spl7() 45 #else 46 #define splclock() splraise4() 47 #define splstatclock() splraise4() 48 #define splhigh() splraise4() 49 #define splsched() splraise4() 50 #define spllock() splraise4() 51 #endif 52 53 #define splx(s) _spl(s) 54 55 #endif /* KERNEL && !_LOCORE */ 56 #endif /* _MACHINE_PSL_H_ */ 57