From 451e9cc3df84f09f43e38a52e6bdc29aafb31166 Mon Sep 17 00:00:00 2001 From: Federico Di Pierro Date: Fri, 14 Feb 2025 12:15:47 +0100 Subject: [PATCH] fix(userspace/libpman): do not use `BPF_PROG_TYPE_TRACING` that may or may not be checkable in `pman_prepare_progs_before_loading`. Instead, use `BPF_PROG_TYPE_RAW_TRACEPOINT` that works fine for the bpf helper probing. Signed-off-by: Federico Di Pierro --- userspace/libpman/src/lifecycle.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/userspace/libpman/src/lifecycle.c b/userspace/libpman/src/lifecycle.c index 125a6b3bb8..8056252832 100644 --- a/userspace/libpman/src/lifecycle.c +++ b/userspace/libpman/src/lifecycle.c @@ -42,7 +42,8 @@ int pman_prepare_progs_before_loading() { bool should_disable = chosen_idx != -1; if(!should_disable) { if(progs[idx].feat > 0 && - libbpf_probe_bpf_helper(BPF_PROG_TYPE_TRACING, progs[idx].feat, NULL) == 0) { + libbpf_probe_bpf_helper(BPF_PROG_TYPE_RAW_TRACEPOINT, progs[idx].feat, NULL) == + 0) { snprintf(msg, MAX_ERROR_MESSAGE_LEN, "BPF program '%s' did not satisfy required feature [%d]",