Support tracing of processes under cgroup path
authorChethan Suresh <Chethan.Suresh@sony.com>
Fri, 10 Dec 2021 04:47:59 +0000 (10:17 +0530)
committeryonghong-song <ys114321@gmail.com>
Sat, 11 Dec 2021 18:56:08 +0000 (10:56 -0800)
commit15340c44b98d8ee97a6dce775de614fd268cee13
tree4aa2f99349284820c9eb5cca03e72227d53ef601
parent60adbc2601dcf2029c2a75acaaaedda4c8d672e3
Support tracing of processes under cgroup path

- Using bpf_current_task_under_cgroup() we can check whether the probe
  is being run in the context of a given subset of the cgroup2 hierarchy.
- Support cgroup path '-c' args to get the cgroup2 path
  and filter based on the cgroup2 path fd using bpf_current_task_under_cgroup()

Signed-off-by: Chethan Suresh <Chethan.Suresh@sony.com>
libbpf-tools/biolatency.bpf.c
libbpf-tools/biolatency.c
libbpf-tools/biosnoop.bpf.c
libbpf-tools/biosnoop.c