diff options
author | Keir Fraser <keir.fraser@citrix.com> | 2009-02-09 14:22:07 +0000 |
---|---|---|
committer | Keir Fraser <keir.fraser@citrix.com> | 2009-02-09 14:22:07 +0000 |
commit | f58273a90cca51f71d87a1fc7d57c61caf028680 (patch) | |
tree | 716512ab6350dc78b9b780f58b676dff3d520b01 /extras | |
parent | c8c2116e93ef6c31afa56a7ac94f6c81ef4ae9e6 (diff) | |
download | xen-f58273a90cca51f71d87a1fc7d57c61caf028680.tar.gz xen-f58273a90cca51f71d87a1fc7d57c61caf028680.tar.bz2 xen-f58273a90cca51f71d87a1fc7d57c61caf028680.zip |
minios: fix p2m on x86
15675:bf85b467ee89 Fixed p2m on x86_64, but instead broke it on x86.
Signed-off-by: Samuel Thibault <samuel.thibaut@ens-lyon.org>
Diffstat (limited to 'extras')
-rw-r--r-- | extras/mini-os/arch/x86/mm.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/extras/mini-os/arch/x86/mm.c b/extras/mini-os/arch/x86/mm.c index 07b6da8d1e..a0e2ae68bc 100644 --- a/extras/mini-os/arch/x86/mm.c +++ b/extras/mini-os/arch/x86/mm.c @@ -550,9 +550,15 @@ static void clear_bootstrap(void) void arch_init_p2m(unsigned long max_pfn) { +#ifdef __x86_64__ #define L1_P2M_SHIFT 9 #define L2_P2M_SHIFT 18 #define L3_P2M_SHIFT 27 +#else +#define L1_P2M_SHIFT 10 +#define L2_P2M_SHIFT 20 +#define L3_P2M_SHIFT 30 +#endif #define L1_P2M_ENTRIES (1 << L1_P2M_SHIFT) #define L2_P2M_ENTRIES (1 << (L2_P2M_SHIFT - L1_P2M_SHIFT)) #define L3_P2M_ENTRIES (1 << (L3_P2M_SHIFT - L2_P2M_SHIFT)) |