From 5d4df7ed707fc4c7b09b48d6bdb122835494f13c Mon Sep 17 00:00:00 2001 From: AlmuHS Date: Mon, 20 May 2019 17:27:19 +0200 Subject: wip: fixed pagging enable in assembly macro (not tested yet) --- i386/i386/cpuboot.S | 18 +++++++++++------- i386/i386/locore.h | 6 ++++++ 2 files changed, 17 insertions(+), 7 deletions(-) diff --git a/i386/i386/cpuboot.S b/i386/i386/cpuboot.S index d50d2dc5..35ef2e92 100644 --- a/i386/i386/cpuboot.S +++ b/i386/i386/cpuboot.S @@ -1,5 +1,7 @@ #include #include +#include +#include #define STACK_SIZE (4096 * 2) @@ -96,9 +98,10 @@ _apboot: #ifndef MACH_HYP //if (!CPU_HAS_FEATURE(CPU_FEATURE_PAE)) - bt %cr4, $CPU_FEATURE_PAE - jc setpae - jnc nopae + mov cpu_features, %eax + test $(1< #include + + /* * Fault recovery in copyin/copyout routines. */ @@ -60,6 +64,8 @@ extern int syscall (void); extern unsigned int cpu_features[1]; +#endif // __ASSEMBLER__ + #define CPU_FEATURE_FPU 0 #define CPU_FEATURE_VME 1 #define CPU_FEATURE_DE 2 -- cgit v1.2.3