.. | .. |
---|
2 | 2 | #ifndef _ASM_MACH_TOPOLOGY_H |
---|
3 | 3 | #define _ASM_MACH_TOPOLOGY_H 1 |
---|
4 | 4 | |
---|
5 | | -#include <asm/sn/hub.h> |
---|
6 | 5 | #include <asm/sn/types.h> |
---|
7 | 6 | #include <asm/mmzone.h> |
---|
8 | 7 | |
---|
9 | 8 | struct cpuinfo_ip27 { |
---|
10 | | -// cpuid_t p_cpuid; /* PROM assigned cpuid */ |
---|
11 | | - cnodeid_t p_nodeid; /* my node ID in compact-id-space */ |
---|
12 | 9 | nasid_t p_nasid; /* my node ID in numa-as-id-space */ |
---|
| 10 | + unsigned short p_speed; /* cpu speed in MHz */ |
---|
13 | 11 | unsigned char p_slice; /* Physical position on node board */ |
---|
14 | | -#if 0 |
---|
15 | | - unsigned long loops_per_sec; |
---|
16 | | - unsigned long ipi_count; |
---|
17 | | - unsigned long irq_attempt[NR_IRQS]; |
---|
18 | | - unsigned long smp_local_irq_count; |
---|
19 | | - unsigned long prof_multiplier; |
---|
20 | | - unsigned long prof_counter; |
---|
21 | | -#endif |
---|
22 | 12 | }; |
---|
23 | 13 | |
---|
24 | 14 | extern struct cpuinfo_ip27 sn_cpu_info[NR_CPUS]; |
---|
25 | 15 | |
---|
26 | | -#define cpu_to_node(cpu) (sn_cpu_info[(cpu)].p_nodeid) |
---|
| 16 | +#define cpu_to_node(cpu) (cputonasid(cpu)) |
---|
27 | 17 | #define cpumask_of_node(node) ((node) == -1 ? \ |
---|
28 | 18 | cpu_all_mask : \ |
---|
29 | 19 | &hub_data(node)->h_cpus) |
---|
30 | 20 | struct pci_bus; |
---|
31 | 21 | extern int pcibus_to_node(struct pci_bus *); |
---|
32 | 22 | |
---|
33 | | -#define cpumask_of_pcibus(bus) (cpu_online_mask) |
---|
| 23 | +#define cpumask_of_pcibus(bus) (cpumask_of_node(pcibus_to_node(bus))) |
---|
34 | 24 | |
---|
35 | | -extern unsigned char __node_distances[MAX_COMPACT_NODES][MAX_COMPACT_NODES]; |
---|
| 25 | +extern unsigned char __node_distances[MAX_NUMNODES][MAX_NUMNODES]; |
---|
36 | 26 | |
---|
37 | 27 | #define node_distance(from, to) (__node_distances[(from)][(to)]) |
---|
38 | 28 | |
---|