aboutsummaryrefslogtreecommitdiffstats
path: root/mm/oom_kill.c
diff options
context:
space:
mode:
authorHugh Dickins <hugh@veritas.com>2007-04-23 17:41:02 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-04-24 11:23:07 -0400
commit3d124cbba316737af8f3a6959edb95bbd130a4d8 (patch)
tree273350d3ce14b1252ff79fd24efa43f39161a200 /mm/oom_kill.c
parentfdc30b3d448bf86dd45f9df3e8ac0d36a3bdd9b2 (diff)
fix OOM killing processes wrongly thought MPOL_BIND
I only have CONFIG_NUMA=y for build testing: surprised when trying a memhog to see lots of other processes killed with "No available memory (MPOL_BIND)". memhog is killed correctly once we initialize nodemask in constrained_alloc(). Signed-off-by: Hugh Dickins <hugh@veritas.com> Acked-by: Christoph Lameter <clameter@sgi.com> Acked-by: William Irwin <bill.irwin@oracle.com> Acked-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> Cc: <stable@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/oom_kill.c')
-rw-r--r--mm/oom_kill.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/mm/oom_kill.c b/mm/oom_kill.c
index af981b645a69..3791edfffeeb 100644
--- a/mm/oom_kill.c
+++ b/mm/oom_kill.c
@@ -176,6 +176,8 @@ static inline int constrained_alloc(struct zonelist *zonelist, gfp_t gfp_mask)
176 struct zone **z; 176 struct zone **z;
177 nodemask_t nodes; 177 nodemask_t nodes;
178 int node; 178 int node;
179
180 nodes_clear(nodes);
179 /* node has memory ? */ 181 /* node has memory ? */
180 for_each_online_node(node) 182 for_each_online_node(node)
181 if (NODE_DATA(node)->node_present_pages) 183 if (NODE_DATA(node)->node_present_pages)