aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/xen/setup.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86/xen/setup.c')
-rw-r--r--arch/x86/xen/setup.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/arch/x86/xen/setup.c b/arch/x86/xen/setup.c
index ead85576d54a..e2d62d697b5d 100644
--- a/arch/x86/xen/setup.c
+++ b/arch/x86/xen/setup.c
@@ -17,6 +17,7 @@
17#include <asm/e820.h> 17#include <asm/e820.h>
18#include <asm/setup.h> 18#include <asm/setup.h>
19#include <asm/acpi.h> 19#include <asm/acpi.h>
20#include <asm/numa.h>
20#include <asm/xen/hypervisor.h> 21#include <asm/xen/hypervisor.h>
21#include <asm/xen/hypercall.h> 22#include <asm/xen/hypercall.h>
22 23
@@ -78,9 +79,16 @@ static void __init xen_add_extra_mem(u64 start, u64 size)
78 memblock_reserve(start, size); 79 memblock_reserve(start, size);
79 80
80 xen_max_p2m_pfn = PFN_DOWN(start + size); 81 xen_max_p2m_pfn = PFN_DOWN(start + size);
82 for (pfn = PFN_DOWN(start); pfn < xen_max_p2m_pfn; pfn++) {
83 unsigned long mfn = pfn_to_mfn(pfn);
84
85 if (WARN(mfn == pfn, "Trying to over-write 1-1 mapping (pfn: %lx)\n", pfn))
86 continue;
87 WARN(mfn != INVALID_P2M_ENTRY, "Trying to remove %lx which has %lx mfn!\n",
88 pfn, mfn);
81 89
82 for (pfn = PFN_DOWN(start); pfn <= xen_max_p2m_pfn; pfn++)
83 __set_phys_to_machine(pfn, INVALID_P2M_ENTRY); 90 __set_phys_to_machine(pfn, INVALID_P2M_ENTRY);
91 }
84} 92}
85 93
86static unsigned long __init xen_do_chunk(unsigned long start, 94static unsigned long __init xen_do_chunk(unsigned long start,
@@ -537,4 +545,7 @@ void __init xen_arch_setup(void)
537 disable_cpufreq(); 545 disable_cpufreq();
538 WARN_ON(set_pm_idle_to_default()); 546 WARN_ON(set_pm_idle_to_default());
539 fiddle_vdso(); 547 fiddle_vdso();
548#ifdef CONFIG_NUMA
549 numa_off = 1;
550#endif
540} 551}