x86/early_ioremap: don't assume we're using swapper_pg_dir
authorJeremy Fitzhardinge <jeremy@xensource.com>
Wed, 13 Feb 2008 15:20:35 +0000 (16:20 +0100)
committerIngo Molnar <mingo@elte.hu>
Wed, 13 Feb 2008 15:20:35 +0000 (16:20 +0100)
commit37cc8d7f963ba2deec29c9b68716944516a3244f
tree33aa30fe472dad9d8f91d1ef653c6be57425e2b4
parent416e2d63794d4e57774989429e174507801915f2
x86/early_ioremap: don't assume we're using swapper_pg_dir

At the early stages of boot, before the kernel pagetable has been
fully initialized, a Xen kernel will still be running off the
Xen-provided pagetables rather than swapper_pg_dir[].  Therefore,
readback cr3 to determine the base of the pagetable rather than
assuming swapper_pg_dir[].

Signed-off-by: Jeremy Fitzhardinge <jeremy@xensource.com>
Tested-by: Jody Belka <knew-linux@pimb.org>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
arch/x86/mm/ioremap.c