Skip to content
Commit b5ad4cdc authored by Feng Zhou's avatar Feng Zhou Committed by Alexei Starovoitov
Browse files

bpf: Add bpf_task_under_cgroup() kfunc



Add a kfunc that's similar to the bpf_current_task_under_cgroup.
The difference is that it is a designated task.

When hook sched related functions, sometimes it is necessary to
specify a task instead of the current task.

Signed-off-by: default avatarFeng Zhou <zhoufeng.zf@bytedance.com>
Acked-by: default avatarYonghong Song <yhs@fb.com>
Link: https://lore.kernel.org/r/20230506031545.35991-2-zhoufeng.zf@bytedance.com


Signed-off-by: default avatarAlexei Starovoitov <ast@kernel.org>
parent f4dea968
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment