blob: 933ff11ece15203a3844ace8fdf66858c3c58be1 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001#ifndef _ASM_X8664_NUMA_H
2#define _ASM_X8664_NUMA_H 1
3
4#include <linux/nodemask.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -07005
Andi Kleenabe059e2006-03-25 16:29:12 +01006struct bootnode {
Linus Torvalds1da177e2005-04-16 15:20:36 -07007 u64 start,end;
8};
9
Andi Kleenabe059e2006-03-25 16:29:12 +010010extern int compute_hash_shift(struct bootnode *nodes, int numnodes);
Linus Torvalds1da177e2005-04-16 15:20:36 -070011
12#define ZONE_ALIGN (1UL << (MAX_ORDER+PAGE_SHIFT))
13
14extern void numa_add_cpu(int cpu);
15extern void numa_init_array(void);
16extern int numa_off;
17
Andi Kleen69d81fc2005-11-05 17:25:53 +010018extern void numa_set_node(int cpu, int node);
Andi Kleen68a3a7f2006-04-07 19:49:18 +020019extern void srat_reserve_add_area(int nodeid);
20extern int hotadd_percent;
Andi Kleen69d81fc2005-11-05 17:25:53 +010021
Andi Kleen0b07e982005-09-12 18:49:24 +020022extern unsigned char apicid_to_node[256];
Ravikiran Thirumalai05b3cbd2006-01-11 22:45:36 +010023#ifdef CONFIG_NUMA
24extern void __init init_cpu_to_node(void);
Ravikiran G Thirumalai488fc082006-02-07 12:58:23 -080025
26static inline void clear_node_cpumask(int cpu)
27{
28 clear_bit(cpu, &node_to_cpumask[cpu_to_node(cpu)]);
29}
30
Ravikiran Thirumalai05b3cbd2006-01-11 22:45:36 +010031#else
32#define init_cpu_to_node() do {} while (0)
Ravikiran G Thirumalai488fc082006-02-07 12:58:23 -080033#define clear_node_cpumask(cpu) do {} while (0)
Ravikiran Thirumalai05b3cbd2006-01-11 22:45:36 +010034#endif
Andi Kleen0b07e982005-09-12 18:49:24 +020035
Linus Torvalds1da177e2005-04-16 15:20:36 -070036#define NUMA_NO_NODE 0xff
37
38#endif