diff options
-rw-r--r-- | arch/x86_64/kernel/e820.c | 2 | ||||
-rw-r--r-- | arch/x86_64/kernel/setup.c | 7 | ||||
-rw-r--r-- | arch/x86_64/mm/init.c | 6 |
3 files changed, 7 insertions, 8 deletions
diff --git a/arch/x86_64/kernel/e820.c b/arch/x86_64/kernel/e820.c index d6d7f731f6f0..1362aad4f3aa 100644 --- a/arch/x86_64/kernel/e820.c +++ b/arch/x86_64/kernel/e820.c | |||
@@ -40,7 +40,7 @@ unsigned long end_pfn_map; | |||
40 | /* | 40 | /* |
41 | * Last pfn which the user wants to use. | 41 | * Last pfn which the user wants to use. |
42 | */ | 42 | */ |
43 | unsigned long end_user_pfn = MAXMEM>>PAGE_SHIFT; | 43 | static unsigned long __initdata end_user_pfn = MAXMEM>>PAGE_SHIFT; |
44 | 44 | ||
45 | extern struct resource code_resource, data_resource; | 45 | extern struct resource code_resource, data_resource; |
46 | 46 | ||
diff --git a/arch/x86_64/kernel/setup.c b/arch/x86_64/kernel/setup.c index aab4bd66aa0d..ddc3b2d9a165 100644 --- a/arch/x86_64/kernel/setup.c +++ b/arch/x86_64/kernel/setup.c | |||
@@ -554,7 +554,7 @@ void __init setup_arch(char **cmdline_p) | |||
554 | * we are rounding upwards: | 554 | * we are rounding upwards: |
555 | */ | 555 | */ |
556 | end_pfn = e820_end_of_ram(); | 556 | end_pfn = e820_end_of_ram(); |
557 | num_physpages = end_pfn; /* for pfn_valid */ | 557 | num_physpages = end_pfn; |
558 | 558 | ||
559 | check_efer(); | 559 | check_efer(); |
560 | 560 | ||
@@ -574,6 +574,11 @@ void __init setup_arch(char **cmdline_p) | |||
574 | acpi_boot_table_init(); | 574 | acpi_boot_table_init(); |
575 | #endif | 575 | #endif |
576 | 576 | ||
577 | /* How many end-of-memory variables you have, grandma! */ | ||
578 | max_low_pfn = end_pfn; | ||
579 | max_pfn = end_pfn; | ||
580 | high_memory = (void *)__va(end_pfn * PAGE_SIZE - 1) + 1; | ||
581 | |||
577 | #ifdef CONFIG_ACPI_NUMA | 582 | #ifdef CONFIG_ACPI_NUMA |
578 | /* | 583 | /* |
579 | * Parse SRAT to discover nodes. | 584 | * Parse SRAT to discover nodes. |
diff --git a/arch/x86_64/mm/init.c b/arch/x86_64/mm/init.c index d14fb2dfbfc4..d40134bd6399 100644 --- a/arch/x86_64/mm/init.c +++ b/arch/x86_64/mm/init.c | |||
@@ -597,12 +597,6 @@ void __init mem_init(void) | |||
597 | 597 | ||
598 | pci_iommu_alloc(); | 598 | pci_iommu_alloc(); |
599 | 599 | ||
600 | /* How many end-of-memory variables you have, grandma! */ | ||
601 | max_low_pfn = end_pfn; | ||
602 | max_pfn = end_pfn; | ||
603 | num_physpages = end_pfn; | ||
604 | high_memory = (void *) __va(end_pfn * PAGE_SIZE); | ||
605 | |||
606 | /* clear the zero-page */ | 600 | /* clear the zero-page */ |
607 | memset(empty_zero_page, 0, PAGE_SIZE); | 601 | memset(empty_zero_page, 0, PAGE_SIZE); |
608 | 602 | ||