]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
x86/ibt: Add ANNOTATE_NOENDBR
authorPeter Zijlstra <peterz@infradead.org>
Tue, 8 Mar 2022 15:30:18 +0000 (16:30 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 26 Aug 2023 12:23:39 +0000 (14:23 +0200)
commitf624ce6c7fc27468cb52623222ed61921822edc0
tree65518f941334dde579c7e7368392a344ab2b91a0
parentf1171d455d94f15ae70b8965b82c3f039f187a63
x86/ibt: Add ANNOTATE_NOENDBR

[ Upstream commit c8c301abeae58ec756b8fcb2178a632bd3c9e284 ]

In order to have objtool warn about code references to !ENDBR
instruction, we need an annotation to allow this for non-control-flow
instances -- consider text range checks, text patching, or return
trampolines etc.

Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Reviewed-by: Kees Cook <keescook@chromium.org>
Acked-by: Josh Poimboeuf <jpoimboe@redhat.com>
Link: https://lore.kernel.org/r/20220308154317.578968224@infradead.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
include/linux/objtool.h
tools/include/linux/objtool.h