On Wed, Feb 22, 2012 at 5:16 PM, tip-bot for Matt Fleming <matt.fleming@xxxxxxxxx> wrote: > Commit-ID: f75bd1837564657b21431e44243e064a77276589 > Gitweb: http://git.kernel.org/tip/f75bd1837564657b21431e44243e064a77276589 > Author: Matt Fleming <matt.fleming@xxxxxxxxx> > AuthorDate: Mon, 20 Feb 2012 13:30:26 +0000 > Committer: H. Peter Anvin <hpa@xxxxxxxxx> > CommitDate: Wed, 22 Feb 2012 14:49:55 -0800 > > x86, efi: Delete efi_ioremap() and fix CONFIG_X86_32 oops > ... > diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c > index d7d5099..e22bb08 100644 > --- a/arch/x86/kernel/setup.c > +++ b/arch/x86/kernel/setup.c > @@ -690,6 +690,8 @@ early_param("reservelow", parse_reservelow); > > void __init setup_arch(char **cmdline_p) > { > + unsigned long end_pfn; > + > #ifdef CONFIG_X86_32 > memcpy(&boot_cpu_data, &new_cpu_data, sizeof(new_cpu_data)); > visws_early_detect(); > @@ -926,7 +928,24 @@ void __init setup_arch(char **cmdline_p) > init_gbpages(); > > /* max_pfn_mapped is updated here */ > - max_low_pfn_mapped = init_memory_mapping(0, max_low_pfn<<PAGE_SHIFT); > + end_pfn = max_low_pfn; > + > +#ifdef CONFIG_X86_64 > + /* > + * There may be regions after the last E820_RAM region that we > + * want to include in the kernel direct mapping because their > + * contents are needed at runtime. > + */ > + if (efi_enabled) { > + unsigned long efi_end; > + > + efi_end = e820_end_pfn(MAXMEM>>PAGE_SHIFT, E820_RESERVED_EFI); > + if (efi_end > end_pfn) > + end_pfn = efi_end; > + } > +#endif > + > + max_low_pfn_mapped = init_memory_mapping(0, end_pfn << PAGE_SHIFT); Why is MAXMEM used here? EFI reserved area could be above 4G? if that is the case, you will map all mmio hole below 4g. Yinghai -- To unsubscribe from this list: send the line "unsubscribe linux-tip-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html