diff options
author | Christoph Lameter <clameter@sgi.com> | 2006-09-26 02:31:55 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-09-26 11:48:52 -0400 |
commit | 89fa30242facca249aead2aac03c4c69764f911c (patch) | |
tree | 1ac46b4777b819f2a4793d8e37330576ae5089ec /mm/vmscan.c | |
parent | 4415cc8df630b05d3a54267d5f3e5c0b63a4ec05 (diff) |
[PATCH] NUMA: Add zone_to_nid function
There are many places where we need to determine the node of a zone.
Currently we use a difficult to read sequence of pointer dereferencing.
Put that into an inline function and use throughout VM. Maybe we can find
a way to optimize the lookup in the future.
Signed-off-by: Christoph Lameter <clameter@sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'mm/vmscan.c')
-rw-r--r-- | mm/vmscan.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/vmscan.c b/mm/vmscan.c index b950f193816e..87779dda4ec6 100644 --- a/mm/vmscan.c +++ b/mm/vmscan.c | |||
@@ -1661,7 +1661,7 @@ int zone_reclaim(struct zone *zone, gfp_t gfp_mask, unsigned int order) | |||
1661 | * over remote processors and spread off node memory allocations | 1661 | * over remote processors and spread off node memory allocations |
1662 | * as wide as possible. | 1662 | * as wide as possible. |
1663 | */ | 1663 | */ |
1664 | node_id = zone->zone_pgdat->node_id; | 1664 | node_id = zone_to_nid(zone); |
1665 | mask = node_to_cpumask(node_id); | 1665 | mask = node_to_cpumask(node_id); |
1666 | if (!cpus_empty(mask) && node_id != numa_node_id()) | 1666 | if (!cpus_empty(mask) && node_id != numa_node_id()) |
1667 | return 0; | 1667 | return 0; |