diff options
author | Mel Gorman <mel@csn.ul.ie> | 2008-04-28 05:12:14 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-04-28 11:58:18 -0400 |
commit | 0e88460da6ab7bb6a7ef83675412ed5b6315d741 (patch) | |
tree | 1feb4de2362e4998a0deeab66af1efb9c7b8bb34 /drivers/char | |
parent | dac1d27bc8d5ca636d3014ecfdf94407031d1970 (diff) |
mm: introduce node_zonelist() for accessing the zonelist for a GFP mask
Introduce a node_zonelist() helper function. It is used to lookup the
appropriate zonelist given a node and a GFP mask. The patch on its own is a
cleanup but it helps clarify parts of the two-zonelist-per-node patchset. If
necessary, it can be merged with the next patch in this set without problems.
Reviewed-by: Christoph Lameter <clameter@sgi.com>
Signed-off-by: Mel Gorman <mel@csn.ul.ie>
Signed-off-by: Lee Schermerhorn <lee.schermerhorn@hp.com>
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: Mel Gorman <mel@csn.ul.ie>
Cc: Christoph Lameter <clameter@sgi.com>
Cc: Hugh Dickins <hugh@veritas.com>
Cc: Nick Piggin <nickpiggin@yahoo.com.au>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/char')
-rw-r--r-- | drivers/char/sysrq.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/char/sysrq.c b/drivers/char/sysrq.c index de60e1ea4fb3..1ade193c9128 100644 --- a/drivers/char/sysrq.c +++ b/drivers/char/sysrq.c | |||
@@ -271,8 +271,7 @@ static struct sysrq_key_op sysrq_term_op = { | |||
271 | 271 | ||
272 | static void moom_callback(struct work_struct *ignored) | 272 | static void moom_callback(struct work_struct *ignored) |
273 | { | 273 | { |
274 | out_of_memory(&NODE_DATA(0)->node_zonelists[ZONE_NORMAL], | 274 | out_of_memory(node_zonelist(0, GFP_KERNEL), GFP_KERNEL, 0); |
275 | GFP_KERNEL, 0); | ||
276 | } | 275 | } |
277 | 276 | ||
278 | static DECLARE_WORK(moom_work, moom_callback); | 277 | static DECLARE_WORK(moom_work, moom_callback); |