[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 06/17] Add prototypes for locore functions
From: |
Guillem Jover |
Subject: |
[PATCH 06/17] Add prototypes for locore functions |
Date: |
Thu, 25 Aug 2011 15:22:29 +0200 |
* 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>.
---
i386/i386/locore.h | 6 ++++++
i386/i386/trap.c | 1 +
i386/i386at/kd.c | 1 +
i386/i386at/model_dep.c | 2 --
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 */
--
1.7.5.4
- Build improvements and warning fixes, Guillem Jover, 2011/08/25
- [PATCH 04/17] Disable compiler built-in symbols to avoid namespace clashes, Guillem Jover, 2011/08/25
- [PATCH 06/17] Add prototypes for locore functions,
Guillem Jover <=
- [PATCH 03/17] Use AC_LANG_SOURCE inside AC_LANG_CONFTEST to fix autoconf warning, Guillem Jover, 2011/08/25
- [PATCH 05/17] Do not take obsolete and unused bcopy and bzero from libc, Guillem Jover, 2011/08/25
- [PATCH 08/17] Add prototype for free_skbuffs function, Guillem Jover, 2011/08/25
- [PATCH 01/17] Add a .gitignore file, Guillem Jover, 2011/08/25
- [PATCH 02/17] Enable silent builds by default if available, Guillem Jover, 2011/08/25