summaryrefslogtreecommitdiff
path: root/i386
diff options
context:
space:
mode:
authorGuillem Jover <guillem@hadrons.org>2011-08-25 15:22:29 +0200
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2011-08-27 00:41:35 +0200
commit01dd59c0b60fded47f60da4be855e3ccaf792d7d (patch)
treec72e240dfb29a898d9fe5b33066f0fc9a43675a8 /i386
parent3da2600b512c23e5db876b806b3b5667af348602 (diff)
Add prototypes for locore functions
* i386/i386at/model_dep.c (discover_x86_cpu_type): Move ... * i386/i386/locore.h: ... here. (inst_fetch, cpu_shutdown): New prototypes. * i386/i386at/kd.c: Include <i386/locore.h>.
Diffstat (limited to 'i386')
-rw-r--r--i386/i386/locore.h6
-rw-r--r--i386/i386/trap.c1
-rw-r--r--i386/i386at/kd.c1
-rw-r--r--i386/i386at/model_dep.c2
4 files changed, 8 insertions, 2 deletions
diff --git a/i386/i386/locore.h b/i386/i386/locore.h
index 5701430..b649726 100644
--- a/i386/i386/locore.h
+++ b/i386/i386/locore.h
@@ -32,8 +32,12 @@ extern int copyout (const void *kernelbuf, void *userbuf, size_t cn);
extern int copyoutmsg (const void *kernelbuf, void *userbuf, size_t cn);
+extern int inst_fetch (int eip, int cs);
+
extern int call_continuation (continuation_t continuation);
+extern void cpu_shutdown (void);
+
extern unsigned int cpu_features[1];
#define CPU_FEATURE_FPU 0
@@ -68,5 +72,7 @@ extern unsigned int cpu_features[1];
#define CPU_HAS_FEATURE(feature) (cpu_features[(feature) / 32] & (1 << ((feature) % 32)))
+extern int discover_x86_cpu_type (void);
+
#endif /* _MACHINE__LOCORE_H_ */
diff --git a/i386/i386/trap.c b/i386/i386/trap.c
index 22dd491..90d4c31 100644
--- a/i386/i386/trap.c
+++ b/i386/i386/trap.c
@@ -33,6 +33,7 @@
#include <mach/machine/eflags.h>
#include <i386/trap.h>
#include <i386/fpu.h>
+#include <i386/locore.h>
#include <i386/model_dep.h>
#include <intel/read_fault.h>
#include <machine/machspl.h> /* for spl_t */
diff --git a/i386/i386at/kd.c b/i386/i386at/kd.c
index e4ac832..af5b792 100644
--- a/i386/i386at/kd.c
+++ b/i386/i386at/kd.c
@@ -85,6 +85,7 @@ WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#include <device/io_req.h>
#include <device/buf.h> /* for struct uio (!) */
#include <vm/vm_kern.h>
+#include <i386/locore.h>
#include <i386/loose_ends.h>
#include <i386/vm_param.h>
#include <i386/machspl.h>
diff --git a/i386/i386at/model_dep.c b/i386/i386at/model_dep.c
index 04b8228..4e7093c 100644
--- a/i386/i386at/model_dep.c
+++ b/i386/i386at/model_dep.c
@@ -128,8 +128,6 @@ extern void setup_main();
void halt_all_cpus (boolean_t reboot) __attribute__ ((noreturn));
void halt_cpu (void) __attribute__ ((noreturn));
-int discover_x86_cpu_type (void);
-
void inittodr(); /* forward */
int rebootflag = 0; /* exported to kdintr */