diff options
Diffstat (limited to 'include/asm-x86/mpspec_def.h')
-rw-r--r-- | include/asm-x86/mpspec_def.h | 87 |
1 files changed, 50 insertions, 37 deletions
diff --git a/include/asm-x86/mpspec_def.h b/include/asm-x86/mpspec_def.h index 13bafb16e7af..3504617fe648 100644 --- a/include/asm-x86/mpspec_def.h +++ b/include/asm-x86/mpspec_def.h | |||
@@ -8,52 +8,68 @@ | |||
8 | 8 | ||
9 | /* | 9 | /* |
10 | * This tag identifies where the SMP configuration | 10 | * This tag identifies where the SMP configuration |
11 | * information is. | 11 | * information is. |
12 | */ | 12 | */ |
13 | 13 | ||
14 | #define SMP_MAGIC_IDENT (('_'<<24)|('P'<<16)|('M'<<8)|'_') | 14 | #define SMP_MAGIC_IDENT (('_'<<24)|('P'<<16)|('M'<<8)|'_') |
15 | 15 | ||
16 | #define MAX_MPC_ENTRY 1024 | 16 | #ifdef CONFIG_X86_32 |
17 | #define MAX_APICS 256 | 17 | # define MAX_MPC_ENTRY 1024 |
18 | # define MAX_APICS 256 | ||
19 | #else | ||
20 | /* | ||
21 | * A maximum of 255 APICs with the current APIC ID architecture. | ||
22 | */ | ||
23 | # define MAX_APICS 255 | ||
24 | #endif | ||
18 | 25 | ||
19 | struct intel_mp_floating | 26 | struct intel_mp_floating |
20 | { | 27 | { |
21 | char mpf_signature[4]; /* "_MP_" */ | 28 | char mpf_signature[4]; /* "_MP_" */ |
22 | unsigned long mpf_physptr; /* Configuration table address */ | 29 | unsigned int mpf_physptr; /* Configuration table address */ |
23 | unsigned char mpf_length; /* Our length (paragraphs) */ | 30 | unsigned char mpf_length; /* Our length (paragraphs) */ |
24 | unsigned char mpf_specification;/* Specification version */ | 31 | unsigned char mpf_specification;/* Specification version */ |
25 | unsigned char mpf_checksum; /* Checksum (makes sum 0) */ | 32 | unsigned char mpf_checksum; /* Checksum (makes sum 0) */ |
26 | unsigned char mpf_feature1; /* Standard or configuration ? */ | 33 | unsigned char mpf_feature1; /* Standard or configuration ? */ |
27 | unsigned char mpf_feature2; /* Bit7 set for IMCR|PIC */ | 34 | unsigned char mpf_feature2; /* Bit7 set for IMCR|PIC */ |
28 | unsigned char mpf_feature3; /* Unused (0) */ | 35 | unsigned char mpf_feature3; /* Unused (0) */ |
29 | unsigned char mpf_feature4; /* Unused (0) */ | 36 | unsigned char mpf_feature4; /* Unused (0) */ |
30 | unsigned char mpf_feature5; /* Unused (0) */ | 37 | unsigned char mpf_feature5; /* Unused (0) */ |
31 | }; | 38 | }; |
32 | 39 | ||
40 | #define MPC_SIGNATURE "PCMP" | ||
41 | |||
33 | struct mp_config_table | 42 | struct mp_config_table |
34 | { | 43 | { |
35 | char mpc_signature[4]; | 44 | char mpc_signature[4]; |
36 | #define MPC_SIGNATURE "PCMP" | ||
37 | unsigned short mpc_length; /* Size of table */ | 45 | unsigned short mpc_length; /* Size of table */ |
38 | char mpc_spec; /* 0x01 */ | 46 | char mpc_spec; /* 0x01 */ |
39 | char mpc_checksum; | 47 | char mpc_checksum; |
40 | char mpc_oem[8]; | 48 | char mpc_oem[8]; |
41 | char mpc_productid[12]; | 49 | char mpc_productid[12]; |
42 | unsigned long mpc_oemptr; /* 0 if not present */ | 50 | unsigned int mpc_oemptr; /* 0 if not present */ |
43 | unsigned short mpc_oemsize; /* 0 if not present */ | 51 | unsigned short mpc_oemsize; /* 0 if not present */ |
44 | unsigned short mpc_oemcount; | 52 | unsigned short mpc_oemcount; |
45 | unsigned long mpc_lapic; /* APIC address */ | 53 | unsigned int mpc_lapic; /* APIC address */ |
46 | unsigned long reserved; | 54 | unsigned int reserved; |
47 | }; | 55 | }; |
48 | 56 | ||
49 | /* Followed by entries */ | 57 | /* Followed by entries */ |
50 | 58 | ||
51 | #define MP_PROCESSOR 0 | 59 | #define MP_PROCESSOR 0 |
52 | #define MP_BUS 1 | 60 | #define MP_BUS 1 |
53 | #define MP_IOAPIC 2 | 61 | #define MP_IOAPIC 2 |
54 | #define MP_INTSRC 3 | 62 | #define MP_INTSRC 3 |
55 | #define MP_LINTSRC 4 | 63 | #define MP_LINTSRC 4 |
56 | #define MP_TRANSLATION 192 /* Used by IBM NUMA-Q to describe node locality */ | 64 | /* Used by IBM NUMA-Q to describe node locality */ |
65 | #define MP_TRANSLATION 192 | ||
66 | |||
67 | #define CPU_ENABLED 1 /* Processor is available */ | ||
68 | #define CPU_BOOTPROCESSOR 2 /* Processor is the BP */ | ||
69 | |||
70 | #define CPU_STEPPING_MASK 0x000F | ||
71 | #define CPU_MODEL_MASK 0x00F0 | ||
72 | #define CPU_FAMILY_MASK 0x0F00 | ||
57 | 73 | ||
58 | struct mpc_config_processor | 74 | struct mpc_config_processor |
59 | { | 75 | { |
@@ -61,14 +77,9 @@ struct mpc_config_processor | |||
61 | unsigned char mpc_apicid; /* Local APIC number */ | 77 | unsigned char mpc_apicid; /* Local APIC number */ |
62 | unsigned char mpc_apicver; /* Its versions */ | 78 | unsigned char mpc_apicver; /* Its versions */ |
63 | unsigned char mpc_cpuflag; | 79 | unsigned char mpc_cpuflag; |
64 | #define CPU_ENABLED 1 /* Processor is available */ | 80 | unsigned int mpc_cpufeature; |
65 | #define CPU_BOOTPROCESSOR 2 /* Processor is the BP */ | 81 | unsigned int mpc_featureflag; /* CPUID feature value */ |
66 | unsigned long mpc_cpufeature; | 82 | unsigned int mpc_reserved[2]; |
67 | #define CPU_STEPPING_MASK 0x0F | ||
68 | #define CPU_MODEL_MASK 0xF0 | ||
69 | #define CPU_FAMILY_MASK 0xF00 | ||
70 | unsigned long mpc_featureflag; /* CPUID feature value */ | ||
71 | unsigned long mpc_reserved[2]; | ||
72 | }; | 83 | }; |
73 | 84 | ||
74 | struct mpc_config_bus | 85 | struct mpc_config_bus |
@@ -98,14 +109,15 @@ struct mpc_config_bus | |||
98 | #define BUSTYPE_VME "VME" | 109 | #define BUSTYPE_VME "VME" |
99 | #define BUSTYPE_XPRESS "XPRESS" | 110 | #define BUSTYPE_XPRESS "XPRESS" |
100 | 111 | ||
112 | #define MPC_APIC_USABLE 0x01 | ||
113 | |||
101 | struct mpc_config_ioapic | 114 | struct mpc_config_ioapic |
102 | { | 115 | { |
103 | unsigned char mpc_type; | 116 | unsigned char mpc_type; |
104 | unsigned char mpc_apicid; | 117 | unsigned char mpc_apicid; |
105 | unsigned char mpc_apicver; | 118 | unsigned char mpc_apicver; |
106 | unsigned char mpc_flags; | 119 | unsigned char mpc_flags; |
107 | #define MPC_APIC_USABLE 0x01 | 120 | unsigned int mpc_apicaddr; |
108 | unsigned long mpc_apicaddr; | ||
109 | }; | 121 | }; |
110 | 122 | ||
111 | struct mpc_config_intsrc | 123 | struct mpc_config_intsrc |
@@ -130,6 +142,7 @@ enum mp_irq_source_types { | |||
130 | #define MP_IRQDIR_HIGH 1 | 142 | #define MP_IRQDIR_HIGH 1 |
131 | #define MP_IRQDIR_LOW 3 | 143 | #define MP_IRQDIR_LOW 3 |
132 | 144 | ||
145 | #define MP_APIC_ALL 0xFF | ||
133 | 146 | ||
134 | struct mpc_config_lintsrc | 147 | struct mpc_config_lintsrc |
135 | { | 148 | { |
@@ -138,15 +151,15 @@ struct mpc_config_lintsrc | |||
138 | unsigned short mpc_irqflag; | 151 | unsigned short mpc_irqflag; |
139 | unsigned char mpc_srcbusid; | 152 | unsigned char mpc_srcbusid; |
140 | unsigned char mpc_srcbusirq; | 153 | unsigned char mpc_srcbusirq; |
141 | unsigned char mpc_destapic; | 154 | unsigned char mpc_destapic; |
142 | #define MP_APIC_ALL 0xFF | ||
143 | unsigned char mpc_destapiclint; | 155 | unsigned char mpc_destapiclint; |
144 | }; | 156 | }; |
145 | 157 | ||
158 | #define MPC_OEM_SIGNATURE "_OEM" | ||
159 | |||
146 | struct mp_config_oemtable | 160 | struct mp_config_oemtable |
147 | { | 161 | { |
148 | char oem_signature[4]; | 162 | char oem_signature[4]; |
149 | #define MPC_OEM_SIGNATURE "_OEM" | ||
150 | unsigned short oem_length; /* Size of table */ | 163 | unsigned short oem_length; /* Size of table */ |
151 | char oem_rev; /* 0x01 */ | 164 | char oem_rev; /* 0x01 */ |
152 | char oem_checksum; | 165 | char oem_checksum; |
@@ -155,13 +168,13 @@ struct mp_config_oemtable | |||
155 | 168 | ||
156 | struct mpc_config_translation | 169 | struct mpc_config_translation |
157 | { | 170 | { |
158 | unsigned char mpc_type; | 171 | unsigned char mpc_type; |
159 | unsigned char trans_len; | 172 | unsigned char trans_len; |
160 | unsigned char trans_type; | 173 | unsigned char trans_type; |
161 | unsigned char trans_quad; | 174 | unsigned char trans_quad; |
162 | unsigned char trans_global; | 175 | unsigned char trans_global; |
163 | unsigned char trans_local; | 176 | unsigned char trans_local; |
164 | unsigned short trans_reserved; | 177 | unsigned short trans_reserved; |
165 | }; | 178 | }; |
166 | 179 | ||
167 | /* | 180 | /* |