aboutsummaryrefslogtreecommitdiff
path: root/init.d/sysfs.in
diff options
context:
space:
mode:
Diffstat (limited to 'init.d/sysfs.in')
-rw-r--r--init.d/sysfs.in17
1 files changed, 9 insertions, 8 deletions
diff --git a/init.d/sysfs.in b/init.d/sysfs.in
index a709e5d9..8809bda2 100644
--- a/init.d/sysfs.in
+++ b/init.d/sysfs.in
@@ -60,15 +60,8 @@ mount_misc()
eend $?
fi
fi
-}
-
-mount_cgroups()
-{
- yesno ${rc_cgroups:-NO} || return 0
- if [ ! -e /proc/cgroups ]; then
- return 0
- fi
+ # set up kernel support for cgroups
if [ -d /sys/fs/cgroup ] && ! mountinfo -q /sys/fs/cgroup; then
if grep -qs cgroup /proc/filesystems; then
ebegin "Mounting cgroup filesystem"
@@ -77,6 +70,14 @@ mount_cgroups()
eend $?
fi
fi
+}
+
+mount_cgroups()
+{
+ yesno ${rc_cgroups:-NO} || return 0
+ if [ ! -e /proc/cgroups ]; then
+ return 0
+ fi
while read name hier groups enabled rest; do
case "${enabled}" in