[lxc-devel] [lxc/lxc] d703c2: cgroupfs: cpuset support for kernels without cgrou...
GitHub
noreply at github.com
Wed Jan 29 09:56:39 UTC 2014
Branch: refs/heads/master
Home: https://github.com/lxc/lxc
Commit: d703c2b15ad39a5a0df4a2b788321481d56c93cf
https://github.com/lxc/lxc/commit/d703c2b15ad39a5a0df4a2b788321481d56c93cf
Author: Robert Vogelgesang <vogel at users.sourceforge.net>
Date: 2014-01-29 (Wed, 29 Jan 2014)
Changed paths:
M src/lxc/cgroup.c
Log Message:
-----------
cgroupfs: cpuset support for kernels without cgroup.clone_children
Hi,
as promised last week, here's my patch for cpuset cgroup support for
kernels without the cgroup.clone_children feature.
My initial patch used "#include <linux/version.h>" and the macros defined
there to decide if cgroup.clone_children should be used or not. After
having seen Serge Hallyn's patch which he posted to the list last Wednesday,
where he used stat() to check if the cgroup.clone_children file is there,
I rewrote my patch to do the same.
The patch is against 1.0.0.beta3, and it is tested successfully with
RHEL-6's kernel version 2.6.32-431.3.1.el6, compiled without cgmanager
(I've so far not tried to use cgmanager in RHEL-6).
In addition to fixing the cpuset cgroup setup, this patch also fixes a
wrong argument in a call to handle_cgroup_settings() in the same context.
Robert
Signed-off-by: Robert Vogelgesang <vogel at users.sourceforge.net>
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Commit: 934b1673cda3f4fc17d66cfe3f429d7fafe3f4a6
https://github.com/lxc/lxc/commit/934b1673cda3f4fc17d66cfe3f429d7fafe3f4a6
Author: Serge Hallyn <serge.hallyn at ubuntu.com>
Date: 2014-01-29 (Wed, 29 Jan 2014)
Changed paths:
M src/lxc/cgroup.c
M src/lxc/cgroup.h
Log Message:
-----------
cgroups: adjust previous commit
Remove a memory leak on error path.
Only try to initialize cpuset if cgroup.clonechildren does not exist.
Bump the max value we read from cpuset.{cpus,mems} to 1024.
If cpuset.cpus or .mems is already initialized but is too long, don't fail.
If parent's cpuset.cpus or .mems is too long, record an error and fail.
If anyone actually runs into this, we can simply allocate the required
length as needed, but we don't expect anyone to run into this.
Signed-off-by: Serge Hallyn <serge.hallyn at ubuntu.com>
Compare: https://github.com/lxc/lxc/compare/9749441a0e80...934b1673cda3
More information about the lxc-devel
mailing list