Li Zefan 3b6766fe66 cpuset: rewrite update_tasks_nodemask()
This patch uses cgroup_scan_tasks() to rebind tasks' vmas to new cpuset's
mems_allowed.

Not only simplify the code largely, but also avoid allocating an array to
hold mm pointers of all the tasks in the cpuset.  This array can be big
(size > PAGESIZE) if we have lots of tasks in that cpuset, thus has a
chance to fail the allocation when under memory stress.

Signed-off-by: Li Zefan <lizf@cn.fujitsu.com>
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: Paul Menage <menage@google.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-04-02 19:04:57 -07:00
..
2009-04-02 19:04:55 -07:00
2008-10-16 11:21:30 -07:00
2009-02-13 09:44:22 +01:00
2009-04-02 19:04:51 -07:00
2008-07-28 14:37:38 +02:00
2009-03-30 21:46:55 +02:00
2007-07-16 09:05:50 -07:00
2009-02-21 14:17:17 -08:00
2009-01-14 18:09:02 +01:00
2009-02-10 00:41:54 +01:00
2009-01-08 08:31:12 -08:00
2008-09-02 19:21:40 -07:00
2009-03-30 22:05:16 +10:30
2009-02-18 19:26:33 +01:00
2009-02-26 21:56:07 +01:00
2009-01-06 11:07:15 +01:00
2009-03-23 09:22:31 -07:00
2008-02-06 10:41:02 -08:00
2009-03-24 10:52:46 +11:00
2008-10-16 11:21:47 -07:00