Skip to content

bpf: Make BPF trampoline friendly to ftrace

Alexei Starovoitov bpf netdev 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 patches 5 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3ftrace: Fix function_graph tracer interaction with BPF trampolinearch/x86/kernel/ftrace.c include/linux/ftrace.h kernel/trace/fgraph.c +1 more+21 -264 replies
2/3bpf: Make BPF trampoline use register_ftrace_direct() APIinclude/linux/bpf.h kernel/bpf/trampoline.c+59 -60 replies
3/3selftests/bpf: test function_graph tracer and bpf trampoline togethertools/testing/selftests/bpf/test_ftrace.sh+39 -00 replies

Reviews trailers per patch

None of the 3 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchMartin KaFai Lau
SeriesA-b
1/3
2/3
3/3

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH bpf 0/3] bpf: Make BPF trampoline friendly to ftrace

Patch 1 - fix crash function_graph tracer encounters BPF trampoline Patch 2 - use register_ftrace_direct() API to attach BPF trampoline Patch 3 - simple test

Alexei Starovoitov (3):
ftrace: Fix function_graph tracer interaction with BPF trampoline
bpf: Make BPF trampoline use register_ftrace_direct() API selftests/bpf: test function_graph tracer and bpf trampoline together

 arch/x86/kernel/ftrace.c                   | 14 -----
 include/linux/bpf.h                        |  1 +
 include/linux/ftrace.h                     |  5 ++
 kernel/bpf/trampoline.c                    | 64 ++++++++++++++++++++--
 kernel/trace/fgraph.c                      |  9 +++
 kernel/trace/ftrace.c                      | 19 +++----
 tools/testing/selftests/bpf/test_ftrace.sh | 39 +++++++++++++
 7 files changed, 119 insertions(+), 32 deletions(-)
 create mode 100755 tools/testing/selftests/bpf/test_ftrace.sh
Signature · 1 line
2.23.0