cpuset: fix the WARN_ON() in update_nodemasks_hier()
authorLi Zefan <lizefan@huawei.com>
Wed, 30 Jul 2014 07:07:13 +0000 (15:07 +0800)
committerTejun Heo <tj@kernel.org>
Wed, 30 Jul 2014 15:26:58 +0000 (11:26 -0400)
The WARN_ON() is used to check if we break the legal hierarchy, on
which the effective mems should be equal to configured mems.

Reported-by: Mike Qiu <qiudayu@linux.vnet.ibm.com>
Tested-by: Mike Qiu <qiudayu@linux.vnet.ibm.com>
Signed-off-by: Li Zefan <lizefan@huawei.com>
kernel/cpuset.c

index f337f42a07ac051e6ae54dda7cbed3bb9284752a..9d7264beb74f547a7b3031c242ddd0c3a6da0599 100644 (file)
@@ -1136,7 +1136,7 @@ static void update_nodemasks_hier(struct cpuset *cs, nodemask_t *new_mems)
                mutex_unlock(&callback_mutex);
 
                WARN_ON(!cgroup_on_dfl(cp->css.cgroup) &&
-                       nodes_equal(cp->mems_allowed, cp->effective_mems));
+                       !nodes_equal(cp->mems_allowed, cp->effective_mems));
 
                update_tasks_nodemask(cp);