debuggers.hg

view xen/include/asm-ia64/linux-xen/asm/numa.h @ 17972:cddaea5d6528

[IA64] removed an unused header file.

removed an unused header file and MAX_NUMNODES were defined in
two place. so removed unnecessary MAX_NUMNODES definitions.

Signed-off-by: Isaku Yamahata <yamahata@valinux.co.jp>
author Isaku Yamahata <yamahata@valinux.co.jp>
date Wed Jun 11 15:38:00 2008 +0900 (2008-06-11)
parents f5d22922444d
children 220f3d62e272
line source
1 /*
2 * This file is subject to the terms and conditions of the GNU General Public
3 * License. See the file "COPYING" in the main directory of this archive
4 * for more details.
5 *
6 * This file contains NUMA specific prototypes and definitions.
7 *
8 * 2002/08/05 Erich Focht <efocht@ess.nec.de>
9 *
10 */
11 #ifndef _ASM_IA64_NUMA_H
12 #define _ASM_IA64_NUMA_H
14 #include <linux/config.h>
16 #ifdef CONFIG_NUMA
18 #include <linux/cache.h>
19 #include <linux/cpumask.h>
20 #include <linux/numa.h>
21 #ifndef XEN /* dependency loop when this is included */
22 #include <linux/smp.h>
23 #endif
24 #include <linux/threads.h>
26 #include <asm/mmzone.h>
28 extern u8 cpu_to_node_map[NR_CPUS] __cacheline_aligned;
29 #ifndef XEN
30 extern cpumask_t node_to_cpu_mask[MAX_NUMNODES] __cacheline_aligned;
31 #else
32 extern cpumask_t node_to_cpu_mask[] __cacheline_aligned;
33 #endif
35 /* Stuff below this line could be architecture independent */
37 extern int num_node_memblks; /* total number of memory chunks */
39 /*
40 * List of node memory chunks. Filled when parsing SRAT table to
41 * obtain information about memory nodes.
42 */
44 struct node_memblk_s {
45 unsigned long start_paddr;
46 unsigned long size;
47 int nid; /* which logical node contains this chunk? */
48 int bank; /* which mem bank on this node */
49 };
51 struct node_cpuid_s {
52 u16 phys_id; /* id << 8 | eid */
53 int nid; /* logical node containing this CPU */
54 };
56 #ifndef XEN
57 extern struct node_memblk_s node_memblk[NR_NODE_MEMBLKS];
58 #else
59 extern struct node_memblk_s node_memblk[];
60 #endif
61 extern struct node_cpuid_s node_cpuid[NR_CPUS];
63 /*
64 * ACPI 2.0 SLIT (System Locality Information Table)
65 * http://devresource.hp.com/devresource/Docs/TechPapers/IA64/slit.pdf
66 *
67 * This is a matrix with "distances" between nodes, they should be
68 * proportional to the memory access latency ratios.
69 */
71 #ifndef XEN
72 extern u8 numa_slit[MAX_NUMNODES * MAX_NUMNODES];
73 #else
74 extern u8 numa_slit[];
75 #endif
76 #define node_distance(from,to) (numa_slit[(from) * num_online_nodes() + (to)])
78 extern int paddr_to_nid(unsigned long paddr);
80 #define local_nodeid (cpu_to_node_map[smp_processor_id()])
82 #else /* !CONFIG_NUMA */
84 #define paddr_to_nid(addr) 0
86 #endif /* CONFIG_NUMA */
88 #ifdef XEN
89 #define phys_to_nid(paddr) paddr_to_nid(paddr)
90 extern int pxm_to_node(int pxm);
91 extern int node_to_pxm(int node);
92 #endif
94 #endif /* _ASM_IA64_NUMA_H */