LKML Archive on
 help / color / Atom feed
* [PATCH v2 0/2] arm: Warn on orphan section placement
@ 2020-06-22 20:49 Kees Cook
  2020-06-22 20:49 ` [PATCH v2 1/2] arm/build: " Kees Cook
  2020-06-22 20:49 ` [PATCH v2 2/2] arm/boot: " Kees Cook
  0 siblings, 2 replies; 8+ messages in thread
From: Kees Cook @ 2020-06-22 20:49 UTC (permalink / raw)
  To: Russell King
  Cc: Kees Cook, Masahiro Yamada, Nick Desaulniers, Nathan Chancellor,
	Will Deacon, Ard Biesheuvel, Arnd Bergmann, linux-arm-kernel,

- split by architecture, rebase to v5.8-rc2

A recent bug[1] was solved for builds linked with ld.lld, and tracking
it down took way longer than it needed to (a year). Ultimately, it
boiled down to differences between ld.bfd and ld.lld's handling of
orphan sections. Similarly, the recent FGKASLR series brough up orphan
section handling too[2]. In both cases, it would have been nice if the
linker was running with --orphan-handling=warn so that surprise sections
wouldn't silently get mapped into the kernel image at locations up to the
whim of the linker's orphan handling logic. Instead, all desired sections
should be explicitly identified in the linker script (to be either kept or
discarded) with any orphans throwing a warning. The powerpc architecture
actually already does this, so this series extends coverage to arm.

This series needs one additional commit that is not yet in
any tree, but I hope to have it landed via x86 -tip shortly:




Kees Cook (2):
  arm/build: Warn on orphan section placement
  arm/boot: Warn on orphan section placement

 arch/arm/Makefile                             |  4 ++++
 arch/arm/boot/compressed/Makefile             |  2 ++
 arch/arm/boot/compressed/        | 17 ++++++--------
 .../arm/{kernel => include/asm}/ | 22 ++++++++++++++-----
 arch/arm/kernel/             |  5 ++---
 arch/arm/kernel/                 |  5 ++---
 6 files changed, 34 insertions(+), 21 deletions(-)
 rename arch/arm/{kernel => include/asm}/ (92%)


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, back to index

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-22 20:49 [PATCH v2 0/2] arm: Warn on orphan section placement Kees Cook
2020-06-22 20:49 ` [PATCH v2 1/2] arm/build: " Kees Cook
2020-06-24  0:03   ` Nick Desaulniers
2020-06-24 19:43     ` Kees Cook
2020-06-26 21:36     ` Nick Desaulniers
2020-06-26 21:55       ` Kees Cook
2020-06-22 20:49 ` [PATCH v2 2/2] arm/boot: " Kees Cook
2020-06-24  0:08   ` Nick Desaulniers

LKML Archive on

Archives are clonable:
	git clone --mirror lkml/git/0.git
	git clone --mirror lkml/git/1.git
	git clone --mirror lkml/git/2.git
	git clone --mirror lkml/git/3.git
	git clone --mirror lkml/git/4.git
	git clone --mirror lkml/git/5.git
	git clone --mirror lkml/git/6.git
	git clone --mirror lkml/git/7.git
	git clone --mirror lkml/git/8.git
	git clone --mirror lkml/git/9.git
	git clone --mirror lkml/git/10.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 lkml lkml/ \
	public-inbox-index lkml

Example config snippet for mirrors

Newsgroup available over NNTP:

AGPL code for this site: git clone