Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/alpha make spl0() and spllowersoftclock() return vo...



details:   https://anonhg.NetBSD.org/src/rev/8b4cdc0b7cda
branches:  trunk
changeset: 487531:8b4cdc0b7cda
user:      cgd <cgd%NetBSD.org@localhost>
date:      Fri Jun 09 01:40:12 2000 +0000

description:
make spl0() and spllowersoftclock() return void.  Also, move spl0()
prototype from param.h to intr.h.  (there were some big XXXs in param.h
that said to do that, and intr.h is included by param.h, so...)

diffstat:

 sys/arch/alpha/alpha/machdep.c |   8 ++++----
 sys/arch/alpha/include/intr.h  |  15 +++++++++++----
 sys/arch/alpha/include/param.h |   6 +-----
 3 files changed, 16 insertions(+), 13 deletions(-)

diffs (85 lines):

diff -r d08b6a0eb4c5 -r 8b4cdc0b7cda sys/arch/alpha/alpha/machdep.c
--- a/sys/arch/alpha/alpha/machdep.c    Fri Jun 09 00:21:08 2000 +0000
+++ b/sys/arch/alpha/alpha/machdep.c    Fri Jun 09 01:40:12 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: machdep.c,v 1.213 2000/06/05 23:44:55 jhawk Exp $ */
+/* $NetBSD: machdep.c,v 1.214 2000/06/09 01:40:13 cgd Exp $ */
 
 /*-
  * Copyright (c) 1998, 1999, 2000 The NetBSD Foundation, Inc.
@@ -73,7 +73,7 @@
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.213 2000/06/05 23:44:55 jhawk Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.214 2000/06/09 01:40:13 cgd Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -1762,7 +1762,7 @@
                fpcurproc = NULL;
 }
 
-int
+void
 spl0()
 {
 
@@ -1771,7 +1771,7 @@
                softintr_dispatch();
        }
 
-       return (alpha_pal_swpipl(ALPHA_PSL_IPL_0));
+       (void) alpha_pal_swpipl(ALPHA_PSL_IPL_0);
 }
 
 /*
diff -r d08b6a0eb4c5 -r 8b4cdc0b7cda sys/arch/alpha/include/intr.h
--- a/sys/arch/alpha/include/intr.h     Fri Jun 09 00:21:08 2000 +0000
+++ b/sys/arch/alpha/include/intr.h     Fri Jun 09 01:40:12 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: intr.h,v 1.28 2000/06/05 21:47:19 thorpej Exp $ */
+/* $NetBSD: intr.h,v 1.29 2000/06/09 01:40:12 cgd Exp $ */
 
 /*-
  * Copyright (c) 2000 The NetBSD Foundation, Inc.
@@ -115,9 +115,16 @@
 #ifdef _KERNEL
 
 /* IPL-lowering/restoring macros */
-#define splx(s)                                                                \
-    ((s) == ALPHA_PSL_IPL_0 ? spl0() : alpha_pal_swpipl(s))
-#define        spllowersoftclock()     alpha_pal_swpipl(ALPHA_PSL_IPL_SOFT)
+void   spl0(void);
+static __inline void
+splx(int s)
+{
+       if (s == ALPHA_PSL_IPL_0)
+               spl0();
+       else
+               alpha_pal_swpipl(s);
+}
+#define        spllowersoftclock()     ((void)alpha_pal_swpipl(ALPHA_PSL_IPL_SOFT))
 
 /* IPL-raising functions/macros */
 static __inline int
diff -r d08b6a0eb4c5 -r 8b4cdc0b7cda sys/arch/alpha/include/param.h
--- a/sys/arch/alpha/include/param.h    Fri Jun 09 00:21:08 2000 +0000
+++ b/sys/arch/alpha/include/param.h    Fri Jun 09 01:40:12 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: param.h,v 1.28 2000/06/08 03:10:06 thorpej Exp $ */
+/* $NetBSD: param.h,v 1.29 2000/06/09 01:40:12 cgd Exp $ */
 
 /*
  * Copyright (c) 1988 University of Utah.
@@ -162,10 +162,6 @@
 void   delay(unsigned long);
 #define        DELAY(n)        delay(n)
 
-/* XXX THE FOLLOWING PROTOTYPE BELONGS IN INTR.H */
-int spl0(void);                                                /* drop ipl to zero */
-/* XXX END INTR.H */
-
 /* XXX THE FOLLOWING PROTOTYPE SHOULD BE A BUS.H INTERFACE */
 paddr_t alpha_XXX_dmamap(vaddr_t);
 /* XXX END BUS.H */



Home | Main Index | Thread Index | Old Index