efi: Quirk out SGI UV
Borislav Petkov
maintainerPATCH 1/1 efi: Quirk out SGI UV
From: Borislav Petkov <[email protected]>
Getting this thing to work with the new mapping scheme would need more work.
Signed-off-by Borislav Petkov <[email protected]>
--- arch/x86/include/asm/efi.h | 1 + arch/x86/kernel/setup.c | 10 ++-------- arch/x86/platform/efi/efi.c | 20 ++++++++++++++++++++ 3 files changed, 23 insertions(+), 8 deletions(-)
arch/x86/include/asm/efi.h +1 -0
@@ -135,6 +135,7 @@ extern void __init old_map_region(efi_memory_desc_t *md);extern void __init runtime_code_page_mkexec (void );extern void __init efi_runtime_mkexec (void );extern void __init efi_dump_pagetable (void ); +extern void __init efi_apply_memmap_quirks (void );struct efi_setup_data {u64 fw_vendor;
arch/x86/kernel/setup.c +2 -8
@@ -1238,14 +1238,8 @@ void __init setup_arch(char **cmdline_p)register_refined_jiffies (CLOCK_TICK_RATE );#ifdef CONFIG_EFI -/* Once setup is done above, unmap the EFI memory map on -* mismatched firmware/kernel archtectures since there is no -* support for runtime services. -*/ -if (efi_enabled (EFI_BOOT ) && !efi_is_native ()) { -pr_info ("efi: Setup done, disabling due to 32/64-bit mismatch\n" ); -efi_unmap_memmap (); - } +if (efi_enabled (EFI_BOOT )) +efi_apply_memmap_quirks ();#endif }
arch/x86/platform/efi/efi.c +20 -0
@@ -52,6 +52,7 @@#include <asm/tlbflush.h> #include <asm/x86_init.h> #include <asm/rtc.h> +#include <asm/uv/uv.h> #define EFI_DEBUG
@@ -1298,3 +1299,22 @@ static int __init parse_efi_cmdline(char *str)return 0 ; }early_param ("efi" , parse_efi_cmdline); + +void __init efi_apply_memmap_quirks (void ) +{ +/* +* Once setup is done earlier, unmap the EFI memory map on mismatched +* firmware/kernel architectures since there is no support for runtime +* services. +*/ +if (!efi_is_native ()) { +pr_info ("efi: Setup done, disabling due to 32/64-bit mismatch\n" ); +efi_unmap_memmap (); + } + +/* +* UV doesn't support the new EFI pagetable mapping yet. +*/ +if (is_uv_system ()) +set_bit (EFI_OLD_MEMMAP , &efi.flags); +}
Signature · 1 line
1.9.0
Matt Fleming
AppliedQuoted 11 lines · Borislav Petkov
From: Borislav Petkov <[email protected]>
Getting this thing to work with the new mapping scheme would need more work.
Signed-off-by Borislav Petkov <[email protected]>--- arch/x86/include/asm/efi.h | 1 + arch/x86/kernel/setup.c | 10 ++-------- arch/x86/platform/efi/efi.c | 20 ++++++++++++++++++++ 3 files changed, 23 insertions(+), 8 deletions(-)
Thanks, applied to 'urgent' with an updated commit message.
Signature · 1 line
Matt Fleming, Intel Open Source Technology Center
Quoted 4 lines · Borislav Petkov
From: Borislav Petkov <[email protected]>
Getting this thing to work with the new mapping scheme would need more work.
Thanks Boris. Allows SGI UV to boot (without the extra bootline).
Quoted 77 lines
Signed-off-by Borislav Petkov <[email protected]>--- arch/x86/include/asm/efi.h | 1 + arch/x86/kernel/setup.c | 10 ++-------- arch/x86/platform/efi/efi.c | 20 ++++++++++++++++++++ 3 files changed, 23 insertions(+), 8 deletions(-)arch/x86/include/asm/efi.h +1
-0@@ -135,6 +135,7 @@ extern void __init old_map_region(efi_memory_desc_t *md);extern void __init runtime_code_page_mkexec (void );extern void __init efi_runtime_mkexec (void );extern void __init efi_dump_pagetable (void ); +extern void __init efi_apply_memmap_quirks (void );struct efi_setup_data {u64 fw_vendor;arch/x86/kernel/setup.c +2
-8@@ -1238,14 +1238,8 @@ void __init setup_arch(char **cmdline_p)register_refined_jiffies (CLOCK_TICK_RATE );#ifdef CONFIG_EFI -/* Once setup is done above, unmap the EFI memory map on -* mismatched firmware/kernel archtectures since there is no -* support for runtime services. -*/ -if (efi_enabled (EFI_BOOT ) && !efi_is_native ()) { -pr_info ("efi: Setup done, disabling due to 32/64-bit mismatch\n" ); -efi_unmap_memmap (); - } +if (efi_enabled (EFI_BOOT )) +efi_apply_memmap_quirks ();#endif }arch/x86/platform/efi/efi.c +20
-0@@ -52,6 +52,7 @@#include <asm/tlbflush.h> #include <asm/x86_init.h> #include <asm/rtc.h> +#include <asm/uv/uv.h> #define EFI_DEBUG @@ -1298,3 +1299,22 @@ static int __init parse_efi_cmdline(char *str)return 0 ; }early_param ("efi" , parse_efi_cmdline); + +void __init efi_apply_memmap_quirks (void ) +{ +/* +* Once setup is done earlier, unmap the EFI memory map on mismatched +* firmware/kernel architectures since there is no support for runtime +* services. +*/ +if (!efi_is_native ()) { +pr_info ("efi: Setup done, disabling due to 32/64-bit mismatch\n" ); +efi_unmap_memmap (); + } + +/* +* UV doesn't support the new EFI pagetable mapping yet. +*/ +if (is_uv_system ()) +set_bit (EFI_OLD_MEMMAP , &efi.flags); +}Signature · 1 line
1.9.0
Signature · 2 lines
Russ Anderson, Kernel and Performance Software Team Manager SGI - Silicon Graphics Inc rja-sJ/[email protected]