[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <159896087591.20229.4965158961256673819.tip-bot2@tip-bot2>
Date: Tue, 01 Sep 2020 11:47:55 -0000
From: "tip-bot2 for Kees Cook" <tip-bot2@...utronix.de>
To: linux-tip-commits@...r.kernel.org
Cc: Nick Desaulniers <ndesaulniers@...gle.com>,
Kees Cook <keescook@...omium.org>,
Ingo Molnar <mingo@...nel.org>,
Fangrui Song <maskray@...gle.com>,
Russell King <linux@...linux.org.uk>, x86 <x86@...nel.org>,
LKML <linux-kernel@...r.kernel.org>
Subject: [tip: core/build] arm/build: Explicitly keep .ARM.attributes sections
The following commit has been merged into the core/build branch of tip:
Commit-ID: 3b14aefb84320ac430cecbdc87b680317916b2bd
Gitweb: https://git.kernel.org/tip/3b14aefb84320ac430cecbdc87b680317916b2bd
Author: Kees Cook <keescook@...omium.org>
AuthorDate: Fri, 21 Aug 2020 12:42:57 -07:00
Committer: Ingo Molnar <mingo@...nel.org>
CommitterDate: Tue, 01 Sep 2020 10:03:18 +02:00
arm/build: Explicitly keep .ARM.attributes sections
In preparation for adding --orphan-handling=warn, explicitly keep the
.ARM.attributes section (at address 0[1]) by expanding the existing
ELF_DETAILS macro into ARM_DETAILS.
[1] https://reviews.llvm.org/D85867
Suggested-by: Nick Desaulniers <ndesaulniers@...gle.com>
Signed-off-by: Kees Cook <keescook@...omium.org>
Signed-off-by: Ingo Molnar <mingo@...nel.org>
Reviewed-by: Fangrui Song <maskray@...gle.com>
Cc: Russell King <linux@...linux.org.uk>
Link: https://lore.kernel.org/lkml/CAKwvOdk-racgq5pxsoGS6Vtifbtrk5fmkmnoLxrQMaOvV0nPWw@mail.gmail.com/
Link: https://lore.kernel.org/r/20200821194310.3089815-17-keescook@chromium.org
---
arch/arm/include/asm/vmlinux.lds.h | 4 ++++
arch/arm/kernel/vmlinux-xip.lds.S | 2 +-
arch/arm/kernel/vmlinux.lds.S | 2 +-
3 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/arch/arm/include/asm/vmlinux.lds.h b/arch/arm/include/asm/vmlinux.lds.h
index a08f430..c4af518 100644
--- a/arch/arm/include/asm/vmlinux.lds.h
+++ b/arch/arm/include/asm/vmlinux.lds.h
@@ -52,6 +52,10 @@
ARM_MMU_DISCARD(*(__ex_table)) \
COMMON_DISCARDS
+#define ARM_DETAILS \
+ ELF_DETAILS \
+ .ARM.attributes 0 : { *(.ARM.attributes) }
+
#define ARM_STUBS_TEXT \
*(.gnu.warning) \
*(.glue_7) \
diff --git a/arch/arm/kernel/vmlinux-xip.lds.S b/arch/arm/kernel/vmlinux-xip.lds.S
index 904c31f..57fcbf5 100644
--- a/arch/arm/kernel/vmlinux-xip.lds.S
+++ b/arch/arm/kernel/vmlinux-xip.lds.S
@@ -150,7 +150,7 @@ SECTIONS
_end = .;
STABS_DEBUG
- ELF_DETAILS
+ ARM_DETAILS
}
/*
diff --git a/arch/arm/kernel/vmlinux.lds.S b/arch/arm/kernel/vmlinux.lds.S
index bb950c8..1d3d3b5 100644
--- a/arch/arm/kernel/vmlinux.lds.S
+++ b/arch/arm/kernel/vmlinux.lds.S
@@ -149,7 +149,7 @@ SECTIONS
_end = .;
STABS_DEBUG
- ELF_DETAILS
+ ARM_DETAILS
}
#ifdef CONFIG_STRICT_KERNEL_RWX
Powered by blists - more mailing lists