diff options
Diffstat (limited to 'include')
| -rw-r--r-- | include/asm-ia64/mmzone.h | 11 | ||||
| -rw-r--r-- | include/asm-ia64/nodedata.h | 2 | ||||
| -rw-r--r-- | include/asm-ia64/numa.h | 2 |
3 files changed, 7 insertions, 8 deletions
diff --git a/include/asm-ia64/mmzone.h b/include/asm-ia64/mmzone.h index 89c392d2dab3..9491dacc89cf 100644 --- a/include/asm-ia64/mmzone.h +++ b/include/asm-ia64/mmzone.h @@ -11,7 +11,7 @@ #ifndef _ASM_IA64_MMZONE_H #define _ASM_IA64_MMZONE_H -#include <linux/config.h> +#include <linux/numa.h> #include <asm/page.h> #include <asm/meminit.h> @@ -19,15 +19,14 @@ #ifdef CONFIG_IA64_DIG /* DIG systems are small */ # define MAX_PHYSNODE_ID 8 -# define NR_NODES 8 -# define NR_NODE_MEMBLKS (NR_NODES * 8) +# define NR_NODE_MEMBLKS (MAX_NUMNODES * 8) #else /* sn2 is the biggest case, so we use that if !DIG */ # define MAX_PHYSNODE_ID 2048 -# define NR_NODES 256 -# define NR_NODE_MEMBLKS (NR_NODES * 4) +# define NR_NODE_MEMBLKS (MAX_NUMNODES * 4) #endif #else /* CONFIG_DISCONTIGMEM */ -# define NR_NODE_MEMBLKS 4 +# define NR_NODE_MEMBLKS (MAX_NUMNODES * 4) #endif /* CONFIG_DISCONTIGMEM */ + #endif /* _ASM_IA64_MMZONE_H */ diff --git a/include/asm-ia64/nodedata.h b/include/asm-ia64/nodedata.h index 90908767b4f2..6b0f3ed89b7e 100644 --- a/include/asm-ia64/nodedata.h +++ b/include/asm-ia64/nodedata.h @@ -27,7 +27,7 @@ struct pglist_data; struct ia64_node_data { short active_cpu_count; short node; - struct pglist_data *pg_data_ptrs[NR_NODES]; + struct pglist_data *pg_data_ptrs[MAX_NUMNODES]; }; diff --git a/include/asm-ia64/numa.h b/include/asm-ia64/numa.h index f62773284501..3ae128fe0823 100644 --- a/include/asm-ia64/numa.h +++ b/include/asm-ia64/numa.h @@ -59,7 +59,7 @@ extern struct node_cpuid_s node_cpuid[NR_CPUS]; */ extern u8 numa_slit[MAX_NUMNODES * MAX_NUMNODES]; -#define node_distance(from,to) (numa_slit[(from) * numnodes + (to)]) +#define node_distance(from,to) (numa_slit[(from) * num_online_nodes() + (to)]) extern int paddr_to_nid(unsigned long paddr); |
