From a3828064be4ed8e95907d3943e7af13cb709694d Mon Sep 17 00:00:00 2001 From: "Huang, Ying" Date: Wed, 30 Jan 2008 13:34:10 +0100 Subject: x86: fixes some bugs about EFI memory map handling This patch fixes some bugs of EFI memory handing code. - On x86_64, it is possible that EFI memory map can not be mapped via identity map, so efi_map_memmap is removed, just use early_ioremap. - On i386, the EFI memory map mapping take effect cross paging_init, so it is not necessary to use efi_map_memmap. - EFI memory map is unmapped in efi_enter_virtual_mode to avoid early_ioremap leak. Signed-off-by: Huang Ying Signed-off-by: Ingo Molnar Signed-off-by: Thomas Gleixner --- arch/x86/kernel/efi_32.c | 15 --------------- 1 file changed, 15 deletions(-) (limited to 'arch/x86/kernel/efi_32.c') diff --git a/arch/x86/kernel/efi_32.c b/arch/x86/kernel/efi_32.c index 114b896d7573..cb91f985b4a1 100644 --- a/arch/x86/kernel/efi_32.c +++ b/arch/x86/kernel/efi_32.c @@ -109,18 +109,3 @@ void efi_call_phys_epilog(void) local_irq_restore(efi_rt_eflags); } - -/* - * We need to map the EFI memory map again after paging_init(). - */ -void __init efi_map_memmap(void) -{ - memmap.map = NULL; - - memmap.map = early_ioremap((unsigned long) memmap.phys_map, - (memmap.nr_map * memmap.desc_size)); - if (memmap.map == NULL) - printk(KERN_ERR "Could not remap the EFI memmap!\n"); - - memmap.map_end = memmap.map + (memmap.nr_map * memmap.desc_size); -} -- cgit v1.2.1