aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/flamegraph.py
diff options
context:
space:
mode:
authorJiri Olsa <[email protected]>2020-08-25 21:21:18 +0200
committerAlexei Starovoitov <[email protected]>2020-08-25 15:37:41 -0700
commitfaaf4a790d93794b46d67e2fd69b8e5c8cae2d41 (patch)
tree8c1f317df4976e485f72c66b0a9c735874b111d9 /tools/perf/scripts/python/flamegraph.py
parent1c6d28a6ac56de5b0af9239a1b02aea4c3011ea3 (diff)
bpf: Add btf_struct_ids_match function
Adding btf_struct_ids_match function to check if given address provided by BTF object + offset is also address of another nested BTF object. This allows to pass an argument to helper, which is defined via parent BTF object + offset, like for bpf_d_path (added in following changes): SEC("fentry/filp_close") int BPF_PROG(prog_close, struct file *file, void *id) { ... ret = bpf_d_path(&file->f_path, ... The first bpf_d_path argument is hold by verifier as BTF file object plus offset of f_path member. The btf_struct_ids_match function will walk the struct file object and check if there's nested struct path object on the given offset. Signed-off-by: Jiri Olsa <[email protected]> Signed-off-by: Alexei Starovoitov <[email protected]> Acked-by: Andrii Nakryiko <[email protected]> Link: https://lore.kernel.org/bpf/[email protected]
Diffstat (limited to 'tools/perf/scripts/python/flamegraph.py')
0 files changed, 0 insertions, 0 deletions