Skip to contentSkip to conversation

efi: old memmap removal followup fixes

PATCH New Ard Biesheuvel 1 participant 3 messages Aug 17, 2020

Subsystems (3)
lore
Share & tools
lore

Ard Biesheuvel

author maintainer
#0 lore raw

cover efi: old memmap removal followup fixes

Now that the old runtime region mapping code is finally gone, we can drop any mention of it from the Documentation, and merge some code that was shared between 32-bit and the old memmap handling code into efi_32.c

Ard Biesheuvel (2):
efi/x86: Move 32-bit code into efi_32.c
Documentation: efi: remove description of efi=old_map

 .../admin-guide/kernel-parameters.txt         |  5 +-
 arch/x86/include/asm/efi.h                    |  4 --
 arch/x86/platform/efi/efi.c                   | 69 -------------------
 arch/x86/platform/efi/efi_32.c                | 45 ++++++++++--
 4 files changed, 39 insertions(+), 84 deletions(-)
Signature · 1 line
2.17.1
author maintainer
#1 lore raw

PATCH 1/2 efi/x86: Move 32-bit code into efi_32.c

Now that the old memmap code has been removed, some code that was left behind in arch/x86/platform/efi/efi.c is only used for 32-bit builds, which means it can live in efi_32.c as well. So move it over.

---
 arch/x86/include/asm/efi.h     |  4 --
 arch/x86/platform/efi/efi.c    | 69 --------------------
 arch/x86/platform/efi/efi_32.c | 45 +++++++++++--
 3 files changed, 38 insertions(+), 80 deletions(-)
arch/x86/include/asm/efi.h +0 -4
index b9c2667ac46c..cff72f4f64ee 100644
@@ -143,17 +143,13 @@ extern void __iomem *__init efi_ioremap(unsigned long addr, unsigned long size,
 #endif /* CONFIG_X86_32 */
 
 extern struct efi_scratch efi_scratch;
-extern void __init efi_set_executable(efi_memory_desc_t *md, bool executable);
 extern int __init efi_memblock_x86_reserve_range(void);
 extern void __init efi_print_memmap(void);
-extern void __init efi_memory_uc(u64 addr, unsigned long size);
 extern void __init efi_map_region(efi_memory_desc_t *md);
 extern void __init efi_map_region_fixed(efi_memory_desc_t *md);
 extern void efi_sync_low_kernel_mappings(void);
 extern int __init efi_alloc_page_tables(void);
 extern int __init efi_setup_page_tables(unsigned long pa_memmap, unsigned num_pages);
-extern void __init old_map_region(efi_memory_desc_t *md);
-extern void __init runtime_code_page_mkexec(void);
 extern void __init efi_runtime_update_mappings(void);
 extern void __init efi_dump_pagetable(void);
 extern void __init efi_apply_memmap_quirks(void);
arch/x86/platform/efi/efi.c +0 -69

81 lines not on this page · raw message

arch/x86/platform/efi/efi_32.c +38 -7

64 lines not on this page · raw message

Signature · 1 line
2.17.1
author maintainer
#2 lore raw

PATCH 2/2 Documentation: efi: remove description of efi=old_map

In reply to Ard Biesheuvel

The old EFI runtime region mapping logic that was kept around for some time has finally been removed entirely, along with the SGI UV1 support code that was its last remaining user. So remove any mention of the efi=old_map command line parameter from the docs.

---
 Documentation/admin-guide/kernel-parameters.txt | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)
Documentation/admin-guide/kernel-parameters.txt +1 -4
index bdc1f33fd3d1..a1068742a6df 100644
@@ -1233,8 +1233,7 @@
 	efi=		[EFI]
 			Format: { "debug", "disable_early_pci_dma",
 				  "nochunk", "noruntime", "nosoftreserve",
-				  "novamap", "no_disable_early_pci_dma",
-				  "old_map" }
+				  "novamap", "no_disable_early_pci_dma" }
 			debug: enable misc debug output.
 			disable_early_pci_dma: disable the busmaster bit on all
 			PCI bridges while in the EFI boot stub.
@@ -1251,8 +1250,6 @@
 			novamap: do not call SetVirtualAddressMap().
 			no_disable_early_pci_dma: Leave the busmaster bit set
 			on all PCI bridges while in the EFI boot stub
-			old_map [X86-64]: switch to the old ioremap-based EFI
-			runtime services mapping. [Needs CONFIG_X86_UV=y]
 
 	efi_no_storage_paranoia [EFI; X86]
 			Using this parameter you can use more than 50% of
Signature · 1 line
2.17.1