Skip to content

Commit 33806e7

Browse files
nathanchancesuryasaimadhu
authored andcommitted
x86/Kconfig: Drop check for -mabi=ms for CONFIG_EFI_STUB
A recent change in LLVM made CONFIG_EFI_STUB unselectable because it no longer pretends to support -mabi=ms, breaking the dependency in Kconfig. Lack of CONFIG_EFI_STUB can prevent kernels from booting via EFI in certain circumstances. This check was added by 8f24f8c ("efi/libstub: Annotate firmware routines as __efiapi") to ensure that __attribute__((ms_abi)) was available, as -mabi=ms is not actually used in any cflags. According to the GCC documentation, this attribute has been supported since GCC 4.4.7. The kernel currently requires GCC 5.1 so this check is not necessary; even when that change landed in 5.6, the kernel required GCC 4.9 so it was unnecessary then as well. Clang supports __attribute__((ms_abi)) for all versions that are supported for building the kernel so no additional check is needed. Remove the 'depends on' line altogether to allow CONFIG_EFI_STUB to be selected when CONFIG_EFI is enabled, regardless of compiler. Fixes: 8f24f8c ("efi/libstub: Annotate firmware routines as __efiapi") Signed-off-by: Nathan Chancellor <[email protected]> Signed-off-by: Borislav Petkov <[email protected]> Reviewed-by: Nick Desaulniers <[email protected]> Acked-by: Ard Biesheuvel <[email protected]> Cc: [email protected] Link: llvm/llvm-project@d1ad006
1 parent a401f45 commit 33806e7

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

arch/x86/Kconfig

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1973,7 +1973,6 @@ config EFI
19731973
config EFI_STUB
19741974
bool "EFI stub support"
19751975
depends on EFI
1976-
depends on $(cc-option,-mabi=ms) || X86_32
19771976
select RELOCATABLE
19781977
help
19791978
This kernel feature allows a bzImage to be loaded directly

0 commit comments

Comments
 (0)