diff options
author | Daniel Xu <dxu@dxuuu.xyz> | 2024-06-12 09:58:36 -0600 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2024-06-12 11:01:32 -0700 |
commit | 770abbb5a25a5b767f1c60ba366aea503728e957 (patch) | |
tree | 93fefc8047f6a553b4e4ce76b3a5e5dab71b444d /Documentation/atomic_bitops.txt | |
parent | c567cba34585514f82600a10587c8813c50e3a7c (diff) |
bpftool: Support dumping kfunc prototypes from BTF
This patch enables dumping kfunc prototypes from bpftool. This is useful
b/c with this patch, end users will no longer have to manually define
kfunc prototypes. For the kernel tree, this also means we can optionally
drop kfunc prototypes from:
tools/testing/selftests/bpf/bpf_kfuncs.h
tools/testing/selftests/bpf/bpf_experimental.h
Example usage:
$ make PAHOLE=/home/dxu/dev/pahole/build/pahole -j30 vmlinux
$ ./tools/bpf/bpftool/bpftool btf dump file ./vmlinux format c | rg "__ksym;" | head -3
extern void cgroup_rstat_updated(struct cgroup *cgrp, int cpu) __weak __ksym;
extern void cgroup_rstat_flush(struct cgroup *cgrp) __weak __ksym;
extern struct bpf_key *bpf_lookup_user_key(u32 serial, u64 flags) __weak __ksym;
Signed-off-by: Daniel Xu <dxu@dxuuu.xyz>
Link: https://lore.kernel.org/r/bf6c08f9263c4bd9d10a717de95199d766a13f61.1718207789.git.dxu@dxuuu.xyz
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'Documentation/atomic_bitops.txt')
0 files changed, 0 insertions, 0 deletions