OSDN Git Service

arm64/build: Assert for unwanted sections
authorKees Cook <keescook@chromium.org>
Fri, 21 Aug 2020 19:42:54 +0000 (12:42 -0700)
committerIngo Molnar <mingo@kernel.org>
Tue, 1 Sep 2020 07:50:37 +0000 (09:50 +0200)
commitbe2881824ae9eb92a35b094f734f9ca7339ddf6d
tree911f7f3f41a51038e4a9ab95cfecfe304680e550
parent578d7f0fd6a5ec8a369a4537c664eb2c8374c134
arm64/build: Assert for unwanted sections

In preparation for warning on orphan sections, discard
unwanted non-zero-sized generated sections, and enforce other
expected-to-be-zero-sized sections (since discarding them might hide
problems with them suddenly gaining unexpected entries).

Suggested-by: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Will Deacon <will@kernel.org>
Link: https://lore.kernel.org/r/20200821194310.3089815-14-keescook@chromium.org
arch/arm64/kernel/vmlinux.lds.S