linux-trace-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/2] x86/retpoline,kprobes: Fix the [__indirect_thunk_start, ..end] range
@ 2023-07-11  9:19 Petr Pavlu
  2023-07-11  9:19 ` [PATCH v2 1/2] x86/retpoline,kprobes: Fix position of thunk sections with CONFIG_LTO_CLANG Petr Pavlu
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Petr Pavlu @ 2023-07-11  9:19 UTC (permalink / raw)
  To: tglx, mingo, bp, dave.hansen, hpa, mhiramat, peterz
  Cc: samitolvanen, x86, linux-trace-kernel, linux-kernel, Petr Pavlu

Fix problems with an output position of thunk sections and the
associated definition of range [__indirect_thunk_start,
__indirect_thunk_end] which affects the kprobes optimization.

Initial v1 of the series kept the mentioned range but it turns out the
logic which uses it is not necessary so it is removed altogether.

Changes since v1 [1]:
- Drop the patch which moved the return thunk out of
  [__indirect_thunk_start, ..end] and instead replace it with a removal
  of the kprobes optimization check which looked for calls to indirect
  thunks.
- Slightly adjust the commit message for the first patch, to better
  match the new second patch.

[1] https://lore.kernel.org/lkml/20230705081547.25130-1-petr.pavlu@suse.com/

Petr Pavlu (2):
  x86/retpoline,kprobes: Fix position of thunk sections with
    CONFIG_LTO_CLANG
  x86/retpoline,kprobes: Skip optprobe check for indirect jumps with
    retpolines and IBT

 arch/x86/include/asm/nospec-branch.h |  3 ---
 arch/x86/kernel/kprobes/opt.c        | 40 +++++++++++-----------------
 arch/x86/kernel/vmlinux.lds.S        |  4 +--
 arch/x86/lib/retpoline.S             |  4 +--
 tools/perf/util/thread-stack.c       |  4 +--
 5 files changed, 20 insertions(+), 35 deletions(-)

-- 
2.35.3


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

end of thread, other threads:[~2023-07-31 10:23 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-07-11  9:19 [PATCH v2 0/2] x86/retpoline,kprobes: Fix the [__indirect_thunk_start, ..end] range Petr Pavlu
2023-07-11  9:19 ` [PATCH v2 1/2] x86/retpoline,kprobes: Fix position of thunk sections with CONFIG_LTO_CLANG Petr Pavlu
2023-07-11  9:19 ` [PATCH v2 2/2] x86/retpoline,kprobes: Skip optprobe check for indirect jumps with retpolines and IBT Petr Pavlu
2023-07-11 12:33   ` Masami Hiramatsu
2023-07-29 15:14 ` [PATCH v2 0/2] x86/retpoline,kprobes: Fix the [__indirect_thunk_start, ..end] range Masami Hiramatsu
2023-07-31 10:22   ` Peter Zijlstra

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).