summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoreivind <eivind@FreeBSD.org>1999-09-26 18:19:49 +0000
committereivind <eivind@FreeBSD.org>1999-09-26 18:19:49 +0000
commite395a206361e3cc87cc94d748590da8b675e54b7 (patch)
treeb796f6f70f7dac0cd3ead943557bfb8e0561fb8c
parent2090db494b5e96bf8dcf30ea751bf985edc28743 (diff)
downloadFreeBSD-src-e395a206361e3cc87cc94d748590da8b675e54b7.zip
FreeBSD-src-e395a206361e3cc87cc94d748590da8b675e54b7.tar.gz
Move the declaration of panic() from sys/systm.h to sys/param.h.
Rationale: Wider access, so we can add assertions to header files. panicstr is still in sys/systm.h Suggested by: phk Discussed with: peter
-rw-r--r--sys/dev/advansys/adwlib.c2
-rw-r--r--sys/i386/i386/mpapic.c2
-rw-r--r--sys/sys/param.h9
-rw-r--r--sys/sys/systm.h1
4 files changed, 11 insertions, 3 deletions
diff --git a/sys/dev/advansys/adwlib.c b/sys/dev/advansys/adwlib.c
index 289c3c6..1195f50 100644
--- a/sys/dev/advansys/adwlib.c
+++ b/sys/dev/advansys/adwlib.c
@@ -44,7 +44,7 @@
* modification.
*/
-#include <sys/types.h>
+#include <sys/param.h>
#include <sys/systm.h>
#include <machine/bus_pio.h>
diff --git a/sys/i386/i386/mpapic.c b/sys/i386/i386/mpapic.c
index ef591aa..ee0a6b3 100644
--- a/sys/i386/i386/mpapic.c
+++ b/sys/i386/i386/mpapic.c
@@ -27,7 +27,7 @@
#include "opt_smp.h"
-#include <sys/types.h>
+#include <sys/param.h>
#include <sys/systm.h>
#include <machine/smptests.h> /** TEST_TEST1 */
diff --git a/sys/sys/param.h b/sys/sys/param.h
index ff68a07..3ae239c 100644
--- a/sys/sys/param.h
+++ b/sys/sys/param.h
@@ -239,4 +239,13 @@
#define ctodb(db) /* calculates pages to devblks */ \
((db) << (PAGE_SHIFT - DEV_BSHIFT))
+
+/*
+ * Make this available for most of the kernel. There were too many
+ * things that included sys/systm.h just for panic().
+ */
+#ifdef KERNEL
+void panic __P((const char *, ...)) __dead2 __printflike(1, 2);
+#endif
+
#endif /* _SYS_PARAM_H_ */
diff --git a/sys/sys/systm.h b/sys/sys/systm.h
index 9ed5a11ff..922b6fc 100644
--- a/sys/sys/systm.h
+++ b/sys/sys/systm.h
@@ -101,7 +101,6 @@ int ureadc __P((int, struct uio *));
void *hashinit __P((int count, struct malloc_type *type, u_long *hashmask));
void *phashinit __P((int count, struct malloc_type *type, u_long *nentries));
-void panic __P((const char *, ...)) __dead2 __printflike(1, 2);
void cpu_boot __P((int));
void cpu_rootconf __P((void));
void tablefull __P((const char *));
OpenPOWER on IntegriCloud