x86: kill bad_ppro
PATCH 1/1 x86: kill bad_ppro
so don't punish all other cpus without that problem when init highmem
Signed-off-by Yinghai Lu <[email protected]>
arch/x86/kernel/setup_32.c +9 -0
@@ -69,6 +69,7 @@#include <asm/cacheflush.h> #include <asm/processor.h> #include <asm/efi.h> +#include <asm/bugs.h> /* This value is set up by the early boot code to point to the value immediately after the boot time page tables. It contains a *physical*
@@ -776,6 +777,14 @@ void __init setup_arch(char **cmdline_p)if (efi_enabled)efi_init (); +if (ppro_with_ram_bug ()) { +e820_update_range (0x70000000ULL ,0x40000ULL ,E820_RAM , +E820_RESERVED ); +sanitize_e820_map (e820.map,ARRAY_SIZE (e820.map), &e820.nr_map); +printk (KERN_INFO "fixed physical RAM map:\n" ); +e820_print_map ("bad_ppro" ); + } +e820_register_active_regions (0 ,0 ,-1UL );/* * partially used pages are not usable - thus
arch/x86/mm/discontig_32.c +2 -2
@@ -405,7 +405,7 @@ void __init zone_sizes_init(void)return ; } -void __init set_highmem_pages_init (int bad_ppro) +void __init set_highmem_pages_init (void ) {#ifdef CONFIG_HIGHMEM struct zone *zone;
@@ -425,7 +425,7 @@ void __init set_highmem_pages_init(int b zone->name, nid, zone_start_pfn, zone_end_pfn);add_highpages_with_active_regions (nid, zone_start_pfn, - zone_end_pfn, bad_ppro); + zone_end_pfn); } totalram_pages += totalhigh_pages;#endif
arch/x86/mm/init_32.c +12 -31
113 lines not on this page · raw message
include/asm-x86/highmem.h +1 -1
@@ -75,7 +75,7 @@ struct page *kmap_atomic_to_page(void *p#define flush_cache_kmaps () do { } while (0)extern void add_highpages_with_active_regions (int nid,unsigned long start_pfn, -unsigned long end_pfn,int bad_ppro); +unsigned long end_pfn);#endif /* __KERNEL__ */
include/asm-x86/numa_32.h +1 -1
@@ -6,7 +6,7 @@ extern void numa_remove_cpu(int cpu);#ifdef CONFIG_NUMA extern void __init remap_numa_kva (void ); -extern void set_highmem_pages_init (int ); +extern void set_highmem_pages_init (void );#else static inline void remap_numa_kva (void ) {
Ingo Molnar
AppliedQuoted 1 line · Yinghai Lu
so don't punish all other cpus without that problem when init highmem
applied to tip/x86/mpparse - nice one! Thanks,
Ingo