Add tests for memory.oom.group
authorJay Kamat <jgkamat@fb.com>
Fri, 7 Sep 2018 21:34:05 +0000 (14:34 -0700)
committerShuah Khan (Samsung OSG) <shuah@kernel.org>
Fri, 7 Sep 2018 22:36:01 +0000 (16:36 -0600)
commita987785dcd6c8ae2915460582aebd6481c81eb67
treec451b56d196e449bade01055bc30dd43eaad8d4d
parent48c2bb0b9cf863e0ed78e269f188ce65b73e0fd1
Add tests for memory.oom.group

Add tests for memory.oom.group for the following cases:
- Killing all processes in a leaf cgroup, but leaving the
  parent untouched
- Killing all processes in a parent and leaf cgroup
- Keeping processes marked by OOM_SCORE_ADJ_MIN alive when considered
  for being killed by the group oom killer.

Signed-off-by: Jay Kamat <jgkamat@fb.com>
Acked-by: Roman Gushchin <guro@fb.com>
Signed-off-by: Shuah Khan (Samsung OSG) <shuah@kernel.org>
tools/testing/selftests/cgroup/cgroup_util.c
tools/testing/selftests/cgroup/cgroup_util.h
tools/testing/selftests/cgroup/test_memcontrol.c