From: David Rientjes Date: Wed, 17 Oct 2007 06:25:58 +0000 (-0700) Subject: oom: do not take callback_mutex X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=3ff566963ce804809af9e32331b287eedeeff501;p=GitHub%2Fmt8127%2Fandroid_kernel_alcatel_ttab.git oom: do not take callback_mutex Since no task descriptor's 'cpuset' field is dereferenced in the execution of the OOM killer anymore, it is no longer necessary to take callback_mutex. [akpm@linux-foundation.org: restore cpuset_lock for other patches] Cc: Andrea Arcangeli Acked-by: Christoph Lameter Signed-off-by: David Rientjes Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/mm/oom_kill.c b/mm/oom_kill.c index d9bba82923d5..183a964ca61b 100644 --- a/mm/oom_kill.c +++ b/mm/oom_kill.c @@ -463,7 +463,6 @@ void out_of_memory(struct zonelist *zonelist, gfp_t gfp_mask, int order) * NUMA) that may require different handling. */ constraint = constrained_alloc(zonelist, gfp_mask); - cpuset_lock(); read_lock(&tasklist_lock); switch (constraint) { @@ -495,7 +494,6 @@ retry: /* Found nothing?!?! Either we hang forever, or we panic. */ if (!p) { read_unlock(&tasklist_lock); - cpuset_unlock(); panic("Out of memory and no killable processes...\n"); } @@ -508,7 +506,6 @@ retry: out: read_unlock(&tasklist_lock); - cpuset_unlock(); /* * Give "p" a good chance of killing itself before we