aboutsummaryrefslogtreecommitdiffstats
path: root/tools/lib/bpf/netlink.c
diff options
context:
space:
mode:
authorAndrii Nakryiko <[email protected]>2024-02-06 00:40:08 +0000
committerAlexei Starovoitov <[email protected]>2024-02-06 04:02:38 +0000
commitc7dcb6c9aa85fa310251dad7e233eb955a5235ed (patch)
tree1b1f362cb3489569fd473d0fda11c678c016df7c /tools/lib/bpf/netlink.c
parentlibbpf: fix return value for PERF_EVENT __arg_ctx type fix up check (diff)
downloadkernel-c7dcb6c9aa85fa310251dad7e233eb955a5235ed.tar.gz
kernel-c7dcb6c9aa85fa310251dad7e233eb955a5235ed.zip
selftests/bpf: mark dynptr kfuncs __weak to make them optional on old kernels
Mark dynptr kfuncs as __weak to allow verifier_global_subprogs/arg_ctx_{perf,kprobe,raw_tp} subtests to be loadable on old kernels. Because bpf_dynptr_from_xdp() kfunc is used from arg_tag_dynptr BPF program in progs/verifier_global_subprogs.c *and* is not marked as __weak, loading any subtest from verifier_global_subprogs fails on old kernels that don't have bpf_dynptr_from_xdp() kfunc defined. Even if arg_tag_dynptr program itself is not loaded, libbpf bails out on non-weak reference to bpf_dynptr_from_xdp (that can't be resolved), which shared across all programs in progs/verifier_global_subprogs.c. So mark all dynptr-related kfuncs as __weak to unblock libbpf CI ([0]). In the upcoming "kfunc in vmlinux.h" work we should make sure that kfuncs are always declared __weak as well. [0] https://github.com/libbpf/libbpf/actions/runs/7792673215/job/21251250831?pr=776#step:4:7961 Signed-off-by: Andrii Nakryiko <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Alexei Starovoitov <[email protected]>
Diffstat (limited to 'tools/lib/bpf/netlink.c')
0 files changed, 0 insertions, 0 deletions