From: Li Zefan Date: Thu, 2 Apr 2009 23:57:52 +0000 (-0700) Subject: cpuset: avoid changing cpuset's mems when errno returned X-Git-Tag: v2.6.30-rc1~346 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=010cfac4ca0f9e85f54ba2117a372e72f4fb9a60;p=pandora-kernel.git cpuset: avoid changing cpuset's mems when errno returned When writing to cpuset.mems, cpuset has to update its mems_allowed before calling update_tasks_nodemask(), but this function might return -ENOMEM. To avoid this rare case, we allocate the memory before changing mems_allowed, and then pass to update_tasks_nodemask(). Similar to what update_cpumask() does. Signed-off-by: Li Zefan Cc: KAMEZAWA Hiroyuki Cc: Paul Menage Cc: Ingo Molnar Cc: Peter Zijlstra Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed