aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorChristoph Lameter <clameter@sgi.com>2007-02-20 16:57:51 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-02-20 20:10:13 -0500
commit74c7aa8b8581e0ba8d6d17c623b9279aaabbb0cf (patch)
treee8bfdd1d4bd5a7d4ee0e0bbf83c45c9f2b5deb59 /net
parent5ec553a90448b3edbd26c1acc72464f877614bfa (diff)
[PATCH] Replace highest_possible_node_id() with nr_node_ids
highest_possible_node_id() is currently used to calculate the last possible node idso that the network subsystem can figure out how to size per node arrays. I think having the ability to determine the maximum amount of nodes in a system at runtime is useful but then we should name this entry correspondingly, it should return the number of node_ids, and the the value needs to be setup only once on bootup. The node_possible_map does not change after bootup. This patch introduces nr_node_ids and replaces the use of highest_possible_node_id(). nr_node_ids is calculated on bootup when the page allocators pagesets are initialized. [deweerdt@free.fr: fix oops] Signed-off-by: Christoph Lameter <clameter@sgi.com> Cc: Neil Brown <neilb@suse.de> Cc: Trond Myklebust <trond.myklebust@fys.uio.no> Signed-off-by: Frederik Deweerdt <frederik.deweerdt@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'net')
-rw-r--r--net/sunrpc/svc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net/sunrpc/svc.c b/net/sunrpc/svc.c
index 4ab137403e1a..232a99715ef2 100644
--- a/net/sunrpc/svc.c
+++ b/net/sunrpc/svc.c
@@ -115,7 +115,7 @@ fail:
115static int 115static int
116svc_pool_map_init_percpu(struct svc_pool_map *m) 116svc_pool_map_init_percpu(struct svc_pool_map *m)
117{ 117{
118 unsigned int maxpools = highest_possible_processor_id()+1; 118 unsigned int maxpools = highest_possible_processor_id() + 1;
119 unsigned int pidx = 0; 119 unsigned int pidx = 0;
120 unsigned int cpu; 120 unsigned int cpu;
121 int err; 121 int err;
@@ -143,7 +143,7 @@ svc_pool_map_init_percpu(struct svc_pool_map *m)
143static int 143static int
144svc_pool_map_init_pernode(struct svc_pool_map *m) 144svc_pool_map_init_pernode(struct svc_pool_map *m)
145{ 145{
146 unsigned int maxpools = highest_possible_node_id()+1; 146 unsigned int maxpools = nr_node_ids;
147 unsigned int pidx = 0; 147 unsigned int pidx = 0;
148 unsigned int node; 148 unsigned int node;
149 int err; 149 int err;