* [GIT PULL] cgroup fixes for v3.11-rc6
@ 2013-08-23 15:48 Tejun Heo
[not found] ` <20130823154813.GE3277-Gd/HAXX7CRxy/B6EtB590w@public.gmane.org>
0 siblings, 1 reply; 2+ messages in thread
From: Tejun Heo @ 2013-08-23 15:48 UTC (permalink / raw)
To: Linus Torvalds
Cc: cgroups-u79uwXL29TY76Z2rM5mHXA,
containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA
Hello, Linus.
A late fix for cgroup. This fixes a behavior regression visible to
userland which was created by a commit merged during -rc1. While the
behavior change isn't too likely to be noticeable, the fix is
relatively low risk and we'll need to backport it through -stable
anyway if the bug gets released.
The fix is available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup.git for-3.11-fixes
for you to fetch changes up to 1c09b195d37fa459844036f429a0f378e70c3db6:
cpuset: fix a regression in validating config change (2013-08-21 08:40:27 -0400)
Thanks.
----------------------------------------------------------------
Li Zefan (1):
cpuset: fix a regression in validating config change
kernel/cpuset.c | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/kernel/cpuset.c b/kernel/cpuset.c
index 010a008..ea1966d 100644
--- a/kernel/cpuset.c
+++ b/kernel/cpuset.c
@@ -475,13 +475,17 @@ static int validate_change(const struct cpuset *cur, const struct cpuset *trial)
/*
* Cpusets with tasks - existing or newly being attached - can't
- * have empty cpus_allowed or mems_allowed.
+ * be changed to have empty cpus_allowed or mems_allowed.
*/
ret = -ENOSPC;
- if ((cgroup_task_count(cur->css.cgroup) || cur->attach_in_progress) &&
- (cpumask_empty(trial->cpus_allowed) &&
- nodes_empty(trial->mems_allowed)))
- goto out;
+ if ((cgroup_task_count(cur->css.cgroup) || cur->attach_in_progress)) {
+ if (!cpumask_empty(cur->cpus_allowed) &&
+ cpumask_empty(trial->cpus_allowed))
+ goto out;
+ if (!nodes_empty(cur->mems_allowed) &&
+ nodes_empty(trial->mems_allowed))
+ goto out;
+ }
ret = 0;
out:
--
tejun
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [GIT PULL RESEND] cgroup fixes for v3.11-rc6
[not found] ` <20130823154813.GE3277-Gd/HAXX7CRxy/B6EtB590w@public.gmane.org>
@ 2013-08-23 15:51 ` Tejun Heo
0 siblings, 0 replies; 2+ messages in thread
From: Tejun Heo @ 2013-08-23 15:51 UTC (permalink / raw)
To: Linus Torvalds
Cc: cgroups-u79uwXL29TY76Z2rM5mHXA,
containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA,
linux-kernel-u79uwXL29TY76Z2rM5mHXA
(forgot to cc lkml, resending, no content change)
Hello, Linus.
A late fix for cgroup. This fixes a behavior regression visible to
userland which was created by a commit merged during -rc1. While the
behavior change isn't too likely to be noticeable, the fix is
relatively low risk and we'll need to backport it through -stable
anyway if the bug gets released.
The fix is available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup.git for-3.11-fixes
for you to fetch changes up to 1c09b195d37fa459844036f429a0f378e70c3db6:
cpuset: fix a regression in validating config change (2013-08-21 08:40:27 -0400)
Thanks.
----------------------------------------------------------------
Li Zefan (1):
cpuset: fix a regression in validating config change
kernel/cpuset.c | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git a/kernel/cpuset.c b/kernel/cpuset.c
index 010a008..ea1966d 100644
--- a/kernel/cpuset.c
+++ b/kernel/cpuset.c
@@ -475,13 +475,17 @@ static int validate_change(const struct cpuset *cur, const struct cpuset *trial)
/*
* Cpusets with tasks - existing or newly being attached - can't
- * have empty cpus_allowed or mems_allowed.
+ * be changed to have empty cpus_allowed or mems_allowed.
*/
ret = -ENOSPC;
- if ((cgroup_task_count(cur->css.cgroup) || cur->attach_in_progress) &&
- (cpumask_empty(trial->cpus_allowed) &&
- nodes_empty(trial->mems_allowed)))
- goto out;
+ if ((cgroup_task_count(cur->css.cgroup) || cur->attach_in_progress)) {
+ if (!cpumask_empty(cur->cpus_allowed) &&
+ cpumask_empty(trial->cpus_allowed))
+ goto out;
+ if (!nodes_empty(cur->mems_allowed) &&
+ nodes_empty(trial->mems_allowed))
+ goto out;
+ }
ret = 0;
out:
--
tejun
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2013-08-23 15:51 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-08-23 15:48 [GIT PULL] cgroup fixes for v3.11-rc6 Tejun Heo
[not found] ` <20130823154813.GE3277-Gd/HAXX7CRxy/B6EtB590w@public.gmane.org>
2013-08-23 15:51 ` [GIT PULL RESEND] " Tejun Heo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).