1 # cgroup2 specific common functions
3 export CGROUP2_PATH="${CGROUP2_PATH:-/sys/fs/cgroup}"
7 if [ `findmnt -d backward -n -o FSTYPE -f ${CGROUP2_PATH}` != "cgroup2" ]; then
8 _notrun "cgroup2 not mounted on ${CGROUP2_PATH}"
11 if [ ! -f "${CGROUP2_PATH}/cgroup.subtree_control" ]; then
12 _notrun "Test requires cgroup2 enabled"
15 if [[ ! $(cat ${CGROUP2_PATH}/cgroup.controllers) =~ $1 ]]; then
16 _notrun "Cgroup2 doesn't support $1 controller $1"