bpf: Factor out cgroup storages operations
authorAndrii Nakryiko <andriin@fb.com>
Wed, 25 Mar 2020 06:57:41 +0000 (23:57 -0700)
committerAlexei Starovoitov <ast@kernel.org>
Thu, 26 Mar 2020 23:36:58 +0000 (16:36 -0700)
commit00c4eddf7ee5cb4941d669d605815454dc9a5419
tree2e663b75a4d9b05d482e34f6172f8f13a11146a7
parentaa131ed44ae1d76637f0dbec33cfcf9115af9bc3
bpf: Factor out cgroup storages operations

Refactor cgroup attach/detach code to abstract away common operations
performed on all types of cgroup storages. This makes high-level logic more
apparent, plus allows to reuse more code across multiple functions.

Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Link: https://lore.kernel.org/bpf/20200325065746.640559-2-andriin@fb.com
kernel/bpf/cgroup.c