From patchwork Tue Mar 24 08:48:10 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 11454833 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id BD774174A for ; Tue, 24 Mar 2020 08:51:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id A091A20870 for ; Tue, 24 Mar 2020 08:51:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1585039862; bh=BOL4zOoIRG4CbE4RpKZIE1QqslU3BGwTFKTI9DAKHao=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=ooug0j//9zbDyBVjivVs9HpcJA5dzB7h9vDRZuADXX2slAN8VucHddJc+7eR0YFTV sMNj7B6pQVlJ5eA4OjzL31KMWxP45rdUQVEW1DhaEaoRzZHzlD46SBZlxs7XESv1+I gkwEiFng6HPZbnm7VR7l6Jn8fFs1NP0UGNzI0BAM= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727163AbgCXIvC (ORCPT ); Tue, 24 Mar 2020 04:51:02 -0400 Received: from conuserg-09.nifty.com ([210.131.2.76]:16879 "EHLO conuserg-09.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726524AbgCXIvC (ORCPT ); Tue, 24 Mar 2020 04:51:02 -0400 Received: from pug.e01.socionext.com (p14092-ipngnfx01kyoto.kyoto.ocn.ne.jp [153.142.97.92]) (authenticated) by conuserg-09.nifty.com with ESMTP id 02O8mgsc011219; Tue, 24 Mar 2020 17:48:50 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-09.nifty.com 02O8mgsc011219 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1585039731; bh=8ZgXz/KQR/y6RDQrCVrZRNgnI7Fumd7RqG2eKtNf9fA=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=g3kZUzkJCkkLC2OUkd+xJPSHVXrMRzLyIqkMDG7axY1hL5t33UVsZ/TSziOfSJPi2 6txC/VowJg3LO1VBZx4Ye2FRWXAcN0fSy9edy9Emx4jsJn2jSLV2BZrHiH+tvOKORa 0RTcz3VNB9zgrDme0MfCEXU80v5Z3L4q/WYRjMR5TC5f4w2YBYDUsRe+96r9TGR/cp 5evyqwH82EufVkuX9xF9dn601/JmYRGl8DQSxwsJfxGQM4703YjSos2W4/ZjNmgMyc zcv60FdGTBJqW3z5Y8gV3T4geS2fFYDO9WLYvmVmdcdwdN9tv2pUE/8DiVq5v0wjvg lfrXH+k0WA66w== X-Nifty-SrcIP: [153.142.97.92] From: Masahiro Yamada To: linux-kernel@vger.kernel.org Cc: "David S . Miller" , Linus Torvalds , Kees Cook , clang-built-linux@googlegroups.com, Herbert Xu , linux-crypto@vger.kernel.org, Ingo Molnar , Thomas Gleixner , Borislav Petkov , Peter Zijlstra , "H . Peter Anvin" , x86@kernel.org, linux-kbuild@vger.kernel.org, Masahiro Yamada Subject: [PATCH 05/16] x86: remove always-defined CONFIG_AS_CFI_SECTIONS Date: Tue, 24 Mar 2020 17:48:10 +0900 Message-Id: <20200324084821.29944-6-masahiroy@kernel.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200324084821.29944-1-masahiroy@kernel.org> References: <20200324084821.29944-1-masahiroy@kernel.org> Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org CONFIG_AS_CFI_SECTIONS was introduced by commit 9e565292270a ("x86: Use .cfi_sections for assembly code"). We raise the minimal supported binutils version from time to time. The last bump was commit 1fb12b35e5ff ("kbuild: Raise the minimum required binutils version to 2.21"). I confirmed the code in $(call as-instr,...) can be assembled by the binutils 2.21 assembler and also by LLVM integrated assembler. Remove CONFIG_AS_CFI_SECTIONS, which is always defined. Signed-off-by: Masahiro Yamada Acked-by: Jason A. Donenfeld Reviewed-by: Nick Desaulniers --- arch/x86/Makefile | 6 ++---- arch/x86/include/asm/dwarf2.h | 2 -- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/arch/x86/Makefile b/arch/x86/Makefile index dd275008fc59..e4a062313bb0 100644 --- a/arch/x86/Makefile +++ b/arch/x86/Makefile @@ -177,8 +177,6 @@ ifeq ($(ACCUMULATE_OUTGOING_ARGS), 1) KBUILD_CFLAGS += $(call cc-option,-maccumulate-outgoing-args,) endif -cfi-sections := $(call as-instr,.cfi_sections .debug_frame,-DCONFIG_AS_CFI_SECTIONS=1) - # does binutils support specific instructions? asinstr += $(call as-instr,pshufb %xmm0$(comma)%xmm0,-DCONFIG_AS_SSSE3=1) avx_instr := $(call as-instr,vxorps %ymm0$(comma)%ymm1$(comma)%ymm2,-DCONFIG_AS_AVX=1) @@ -188,8 +186,8 @@ sha1_ni_instr :=$(call as-instr,sha1msg1 %xmm0$(comma)%xmm1,-DCONFIG_AS_SHA1_NI= sha256_ni_instr :=$(call as-instr,sha256msg1 %xmm0$(comma)%xmm1,-DCONFIG_AS_SHA256_NI=1) adx_instr := $(call as-instr,adox %r10$(comma)%r10,-DCONFIG_AS_ADX=1) -KBUILD_AFLAGS += $(cfi-sections) $(asinstr) $(avx_instr) $(avx2_instr) $(avx512_instr) $(sha1_ni_instr) $(sha256_ni_instr) $(adx_instr) -KBUILD_CFLAGS += $(cfi-sections) $(asinstr) $(avx_instr) $(avx2_instr) $(avx512_instr) $(sha1_ni_instr) $(sha256_ni_instr) $(adx_instr) +KBUILD_AFLAGS += $(asinstr) $(avx_instr) $(avx2_instr) $(avx512_instr) $(sha1_ni_instr) $(sha256_ni_instr) $(adx_instr) +KBUILD_CFLAGS += $(asinstr) $(avx_instr) $(avx2_instr) $(avx512_instr) $(sha1_ni_instr) $(sha256_ni_instr) $(adx_instr) KBUILD_LDFLAGS := -m elf_$(UTS_MACHINE) diff --git a/arch/x86/include/asm/dwarf2.h b/arch/x86/include/asm/dwarf2.h index f440790f09f9..c1e0c315a622 100644 --- a/arch/x86/include/asm/dwarf2.h +++ b/arch/x86/include/asm/dwarf2.h @@ -21,7 +21,6 @@ #define CFI_UNDEFINED .cfi_undefined #define CFI_ESCAPE .cfi_escape -#if defined(CONFIG_AS_CFI_SECTIONS) #ifndef BUILD_VDSO /* * Emit CFI data in .debug_frame sections, not .eh_frame sections. @@ -38,6 +37,5 @@ */ .cfi_sections .eh_frame, .debug_frame #endif -#endif #endif /* _ASM_X86_DWARF2_H */