lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <166602742896.401.9259475718093994169.tip-bot2@tip-bot2>
Date:   Mon, 17 Oct 2022 17:23:48 -0000
From:   "tip-bot2 for Nathan Chancellor" <tip-bot2@...utronix.de>
To:     linux-tip-commits@...r.kernel.org
Cc:     Nathan Chancellor <nathan@...nel.org>,
        Borislav Petkov <bp@...e.de>,
        Nick Desaulniers <ndesaulniers@...gle.com>,
        Ard Biesheuvel <ardb@...nel.org>, stable@...r.kernel.org,
        x86@...nel.org, linux-kernel@...r.kernel.org
Subject: [tip: x86/urgent] x86/Kconfig: Drop check for -mabi=ms for CONFIG_EFI_STUB

The following commit has been merged into the x86/urgent branch of tip:

Commit-ID:     33806e7cb8d50379f55c3e8f335e91e1b359dc7b
Gitweb:        https://git.kernel.org/tip/33806e7cb8d50379f55c3e8f335e91e1b359dc7b
Author:        Nathan Chancellor <nathan@...nel.org>
AuthorDate:    Thu, 29 Sep 2022 08:20:10 -07:00
Committer:     Borislav Petkov <bp@...e.de>
CommitterDate: Mon, 17 Oct 2022 19:11:16 +02:00

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

  8f24f8c2fc82 ("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: 8f24f8c2fc82 ("efi/libstub: Annotate firmware routines as __efiapi")
Signed-off-by: Nathan Chancellor <nathan@...nel.org>
Signed-off-by: Borislav Petkov <bp@...e.de>
Reviewed-by: Nick Desaulniers <ndesaulniers@...gle.com>
Acked-by: Ard Biesheuvel <ardb@...nel.org>
Cc: stable@...r.kernel.org
Link: https://github.com/llvm/llvm-project/commit/d1ad006a8f64bdc17f618deffa9e7c91d82c444d
---
 arch/x86/Kconfig | 1 -
 1 file changed, 1 deletion(-)

diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index 6d1879e..67745ce 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -1973,7 +1973,6 @@ config EFI
 config EFI_STUB
 	bool "EFI stub support"
 	depends on EFI
-	depends on $(cc-option,-mabi=ms) || X86_32
 	select RELOCATABLE
 	help
 	  This kernel feature allows a bzImage to be loaded directly

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ