From e0daceb9717f0a9be4af2e1b19e9316246aed548 Mon Sep 17 00:00:00 2001 From: John Fastabend Date: Tue, 14 Jan 2025 21:40:17 -0800 Subject: [PATCH] tetragon: add get_current_task_btf Add get_current_task_btf so we can reduce bpf_probe_read usage and start using BTF pointer walking on newer kernels. Signed-off-by: John Fastabend --- bpf/include/api.h | 1 + 1 file changed, 1 insertion(+) diff --git a/bpf/include/api.h b/bpf/include/api.h index 82026545cdf..e61b061b963 100644 --- a/bpf/include/api.h +++ b/bpf/include/api.h @@ -235,6 +235,7 @@ static int BPF_FUNC(fib_lookup, void *ctx, struct bpf_fib_lookup *params, uint32 /* Current Process Info */ static uint64_t BPF_FUNC(get_current_task); +static uint64_t BPF_FUNC(get_current_task_btf); static uint64_t BPF_FUNC(get_current_cgroup_id); static uint64_t BPF_FUNC(get_current_ancestor_cgroup_id, int ancestor_level); static uint64_t BPF_FUNC(get_current_uid_gid);