summaryrefslogtreecommitdiff
path: root/sys/arch/sgi/include/intr.h
diff options
context:
space:
mode:
Diffstat (limited to 'sys/arch/sgi/include/intr.h')
-rw-r--r--sys/arch/sgi/include/intr.h32
1 files changed, 5 insertions, 27 deletions
diff --git a/sys/arch/sgi/include/intr.h b/sys/arch/sgi/include/intr.h
index 4f45611e1e6..41edd3da02b 100644
--- a/sys/arch/sgi/include/intr.h
+++ b/sys/arch/sgi/include/intr.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: intr.h,v 1.15 2006/07/09 22:10:05 mk Exp $ */
+/* $OpenBSD: intr.h,v 1.16 2007/03/23 21:07:39 miod Exp $ */
/*
* Copyright (c) 2001-2004 Opsycon AB (www.opsycon.se / www.opsycon.com)
@@ -81,7 +81,6 @@
#ifndef _LOCORE
-#if 1
#define splbio() splraise(imask[IPL_BIO])
#define splnet() splraise(imask[IPL_NET])
#define spltty() splraise(imask[IPL_TTY])
@@ -91,24 +90,15 @@
#define splsoftclock() splraise(SINT_CLOCKMASK)
#define splsoftnet() splraise(SINT_NETMASK|SINT_CLOCKMASK)
#define splsofttty() splraise(SINT_TTYMASK)
-#else
-#define splbio() splhigh()
-#define splnet() splhigh()
-#define spltty() splhigh()
-#define splclock() splhigh()
-#define splvm() splhigh()
-#define splsoftclock() splhigh()
-#define splsoftnet() splhigh()
-#define splsofttty() splhigh()
-#endif
#define splstatclock() splhigh()
#define splhigh() splraise(-1)
#define spl0() spllower(0)
+#include <machine/atomic.h>
-#define setsoftclock() set_ipending(SINT_CLOCKMASK);
-#define setsoftnet() set_ipending(SINT_NETMASK);
-#define setsofttty() set_ipending(SINT_TTYMASK);
+#define setsoftclock() atomic_setbits_int(&ipending, SINT_CLOCKMASK)
+#define setsoftnet() atomic_setbits_int(&ipending, SINT_NETMASK)
+#define setsofttty() atomic_setbits_int(&ipending, SINT_TTYMASK)
void splinit(void);
@@ -129,12 +119,6 @@ typedef u_int32_t intrmask_t; /* Type of var holding interrupt mask */
#define INTMASKSIZE (sizeof(intrmask_t) * 8)
-void clearsoftclock(void);
-void clearsoftnet(void);
-#if 0
-void clearsofttty(void);
-#endif
-
extern volatile intrmask_t cpl;
extern volatile intrmask_t ipending;
extern volatile intrmask_t astpending;
@@ -204,12 +188,6 @@ spllower(int newcpl)
}
/*
- * Atomically update ipending.
- */
-void set_ipending(int);
-void clr_ipending(int);
-
-/*
* Interrupt control struct used by interrupt dispatchers
* to hold interrupt handler info.
*/