summaryrefslogtreecommitdiff
path: root/tools/lib/bpf/netlink.c
diff options
context:
space:
mode:
authorAndrii Nakryiko <andrii@kernel.org>2024-02-05 16:22:43 -0800
committerSasha Levin <sashal@kernel.org>2024-03-26 18:16:39 -0400
commitaf129d11f9832f6b39b3dc9d0314d77c504499ad (patch)
tree44a4e3eae1f2c0749c6c4d1773addff3c9141c47 /tools/lib/bpf/netlink.c
parentf8b7bad1506436462237ac38b57d39c737888f46 (diff)
libbpf: fix return value for PERF_EVENT __arg_ctx type fix up check
[ Upstream commit d7bc416aa5cc183691287e8f0b1d5b182a7ce9c3 ] If PERF_EVENT program has __arg_ctx argument with matching architecture-specific pt_regs/user_pt_regs/user_regs_struct pointer type, libbpf should still perform type rewrite for old kernels, but not emit the warning. Fix copy/paste from kernel code where 0 is meant to signify "no error" condition. For libbpf we need to return "true" to proceed with type rewrite (which for PERF_EVENT program will be a canonical `struct bpf_perf_event_data *` type). Fixes: 9eea8fafe33e ("libbpf: fix __arg_ctx type enforcement for perf_event programs") Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/r/20240206002243.1439450-1-andrii@kernel.org Signed-off-by: Alexei Starovoitov <ast@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'tools/lib/bpf/netlink.c')
0 files changed, 0 insertions, 0 deletions