initd: mount cgroup
authorLuka Perkov <luka@openwrt.org>
Tue, 11 Nov 2014 12:28:19 +0000 (12:28 +0000)
committerJohn Crispin <blogic@openwrt.org>
Fri, 14 Nov 2014 14:21:42 +0000 (15:21 +0100)
If kernel is compiled with cgroup support it should be mounted. This change
does not effect kernels without cgroup support.

Signed-off-by: Luka Perkov <luka@openwrt.org>
initd/early.c

index a9f6afb..c622aec 100644 (file)
@@ -29,6 +29,7 @@ early_mounts(void)
 {
        mount("proc", "/proc", "proc", MS_NOATIME, 0);
        mount("sysfs", "/sys", "sysfs", MS_NOATIME, 0);
+       mount("none", "/sys/fs/cgroup", "cgroup", 0, 0);
 
        mount("tmpfs", "/tmp", "tmpfs", MS_NOSUID | MS_NODEV | MS_NOATIME, NULL);
        mkdir("/tmp/run", 0777);