* [tip: x86/urgent] x86/alternative: Report missing return thunk details
@ 2022-07-21 8:37 tip-bot2 for Kees Cook
0 siblings, 0 replies; only message in thread
From: tip-bot2 for Kees Cook @ 2022-07-21 8:37 UTC (permalink / raw)
To: linux-tip-commits; +Cc: Peter Zijlstra, Kees Cook, x86, linux-kernel
The following commit has been merged into the x86/urgent branch of tip:
Commit-ID: 65cdf0d623bedf0e069bb64ed52e8bb20105e2ba
Gitweb: https://git.kernel.org/tip/65cdf0d623bedf0e069bb64ed52e8bb20105e2ba
Author: Kees Cook <keescook@chromium.org>
AuthorDate: Wed, 13 Jul 2022 14:38:19 -07:00
Committer: Peter Zijlstra <peterz@infradead.org>
CommitterDate: Wed, 20 Jul 2022 19:24:53 +02:00
x86/alternative: Report missing return thunk details
Debugging missing return thunks is easier if we can see where they're
happening.
Suggested-by: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://lore.kernel.org/lkml/Ys66hwtFcGbYmoiZ@hirez.programming.kicks-ass.net/
---
arch/x86/kernel/alternative.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/arch/x86/kernel/alternative.c b/arch/x86/kernel/alternative.c
index d685853..62f6b8b 100644
--- a/arch/x86/kernel/alternative.c
+++ b/arch/x86/kernel/alternative.c
@@ -555,7 +555,9 @@ void __init_or_module noinline apply_returns(s32 *start, s32 *end)
dest = addr + insn.length + insn.immediate.value;
if (__static_call_fixup(addr, op, dest) ||
- WARN_ON_ONCE(dest != &__x86_return_thunk))
+ WARN_ONCE(dest != &__x86_return_thunk,
+ "missing return thunk: %pS-%pS: %*ph",
+ addr, dest, 5, addr))
continue;
DPRINTK("return thunk at: %pS (%px) len: %d to: %pS",
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-07-21 8:38 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-21 8:37 [tip: x86/urgent] x86/alternative: Report missing return thunk details tip-bot2 for Kees Cook
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®