]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
bpf: Allow skb_ancestor_cgroup_id helper in cgroup skb
authorAndrey Ignatov <rdna@fb.com>
Thu, 14 May 2020 20:03:46 +0000 (13:03 -0700)
committerAlexei Starovoitov <ast@kernel.org>
Fri, 15 May 2020 01:41:07 +0000 (18:41 -0700)
commit06d3e4c9f11afc849dc201ecf9ef7a43eeb1dddd
treeb5deca627ef2679e3715b57c3ba611c2f15bc16e
parentd56c2f95adb3d401bf982b6cf8fc4bb6d2f7acdd
bpf: Allow skb_ancestor_cgroup_id helper in cgroup skb

cgroup skb programs already can use bpf_skb_cgroup_id. Allow
bpf_skb_ancestor_cgroup_id as well so that container policies can be
implemented for a container that can have sub-cgroups dynamically
created, but policies should still be implemented based on cgroup id of
container itself not on an id of a sub-cgroup.

Signed-off-by: Andrey Ignatov <rdna@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Acked-by: Yonghong Song <yhs@fb.com>
Link: https://lore.kernel.org/bpf/8874194d6041eba190356453ea9f6071edf5f658.1589486450.git.rdna@fb.com
net/core/filter.c