kselftests: cgroup: add freezer mkdir test
authorRoman Gushchin <guro@fb.com>
Thu, 12 Sep 2019 17:56:44 +0000 (10:56 -0700)
committerTejun Heo <tj@kernel.org>
Thu, 12 Sep 2019 21:04:40 +0000 (14:04 -0700)
commit44e9d308a51fbf6d2e5a913f7452a5d5f1902249
tree2af3fa472bb1fba03698ef3367073149d409336f
parent505a8ec7e11ae5236c4a154a1e24ef49a8349600
kselftests: cgroup: add freezer mkdir test

Add a new cgroup freezer selftest, which checks that if a cgroup is
frozen, their new child cgroups will properly inherit the frozen
state.

It creates a parent cgroup, freezes it, creates a child cgroup
and populates it with a dummy process. Then it checks that both
parent and child cgroup are frozen.

Signed-off-by: Roman Gushchin <guro@fb.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Shuah Khan <shuah@kernel.org>
Signed-off-by: Tejun Heo <tj@kernel.org>
tools/testing/selftests/cgroup/test_freezer.c