summaryrefslogtreecommitdiff
path: root/sys/arch
diff options
context:
space:
mode:
authorMark Kettenis <kettenis@cvs.openbsd.org>2008-01-15 19:30:33 +0000
committerMark Kettenis <kettenis@cvs.openbsd.org>2008-01-15 19:30:33 +0000
commit1d494dc429c865582c9ab9e9fbdd77941676ac94 (patch)
tree6e27bec845baf4c8e9d25f36c5c43bd5dad2fe7e /sys/arch
parent001348bcef7a91c2082b22e73576944eb5321a47 (diff)
Move some definitions from mpconfig.h to mpbiosreg.h (where they are on i396).
ok marco@, miod@
Diffstat (limited to 'sys/arch')
-rw-r--r--sys/arch/amd64/include/mpbiosreg.h27
-rw-r--r--sys/arch/amd64/include/mpconfig.h18
2 files changed, 27 insertions, 18 deletions
diff --git a/sys/arch/amd64/include/mpbiosreg.h b/sys/arch/amd64/include/mpbiosreg.h
index 8041f5bb930..e93f5eed0bc 100644
--- a/sys/arch/amd64/include/mpbiosreg.h
+++ b/sys/arch/amd64/include/mpbiosreg.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: mpbiosreg.h,v 1.1 2004/01/28 01:39:39 mickey Exp $ */
+/* $OpenBSD: mpbiosreg.h,v 1.2 2008/01/15 19:30:32 kettenis Exp $ */
/* $NetBSD: mpbiosreg.h,v 1.3 2003/03/04 23:27:32 fvdl Exp $ */
/*-
@@ -58,6 +58,31 @@
#define MPS_MCT_NTYPES 5
+/*
+ * Interrupt typess
+ */
+
+#define MPS_INTTYPE_INT 0
+#define MPS_INTTYPE_NMI 1
+#define MPS_INTTYPE_SMI 2
+#define MPS_INTTYPE_ExtINT 3
+
+#define MPS_INTPO_DEF 0
+#define MPS_INTPO_ACTHI 1
+#define MPS_INTPO_ACTLO 3
+#define MPS_INTPO_SHIFT 0
+#define MPS_INTPO_MASK 3
+
+#define MPS_INTTR_DEF 0
+#define MPS_INTTR_EDGE 1
+#define MPS_INTTR_LEVEL 3
+#define MPS_INTTR_SHIFT 2
+#define MPS_INTTR_MASK 3
+
+#define MPS_INT(p,t) \
+ ((((p) & MPS_INTPO_MASK) << MPS_INTPO_SHIFT) | \
+ (((t) & MPS_INTTR_MASK) << MPS_INTTR_SHIFT))
+
/* MP Floating Pointer Structure */
struct mpbios_fps {
u_int32_t signature;
diff --git a/sys/arch/amd64/include/mpconfig.h b/sys/arch/amd64/include/mpconfig.h
index 3ad87939f47..d42d0b37dca 100644
--- a/sys/arch/amd64/include/mpconfig.h
+++ b/sys/arch/amd64/include/mpconfig.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: mpconfig.h,v 1.5 2007/11/16 16:16:07 deraadt Exp $ */
+/* $OpenBSD: mpconfig.h,v 1.6 2008/01/15 19:30:32 kettenis Exp $ */
/* $NetBSD: mpconfig.h,v 1.2 2003/05/11 00:05:52 fvdl Exp $ */
/*
@@ -9,22 +9,6 @@
#ifndef _AMD64_MPCONFIG_H
#define _AMD64_MPCONFIG_H
-/*
- * Interrupt typess
- */
-#define MPS_INTTYPE_INT 0
-#define MPS_INTTYPE_NMI 1
-#define MPS_INTTYPE_SMI 2
-#define MPS_INTTYPE_ExtINT 3
-
-#define MPS_INTPO_DEF 0
-#define MPS_INTPO_ACTHI 1
-#define MPS_INTPO_ACTLO 3
-
-#define MPS_INTTR_DEF 0
-#define MPS_INTTR_EDGE 1
-#define MPS_INTTR_LEVEL 3
-
#ifndef _LOCORE
struct mpbios_int;