diff options
author | Alexey Starikovskiy <astarikovskiy@suse.de> | 2008-03-17 15:08:55 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-04-17 11:41:08 -0400 |
commit | 864205062f1c752c80077be8ec2b15c81f4a6525 (patch) | |
tree | b240a81db36c029ed6274f5775a05981d0b5816b | |
parent | 0ec153af4dec8944e6da558093914a3bce4c76f9 (diff) |
x86: make struct mpc_config_translation NUMAQ-only
Signed-off-by: Alexey Starikovskiy <astarikovskiy@suse.de>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
-rw-r--r-- | arch/x86/kernel/mpparse_32.c | 6 | ||||
-rw-r--r-- | include/asm-x86/genapic_32.h | 1 | ||||
-rw-r--r-- | include/asm-x86/mach-numaq/mach_apic.h | 10 | ||||
-rw-r--r-- | include/asm-x86/mpspec_def.h | 11 |
4 files changed, 16 insertions, 12 deletions
diff --git a/arch/x86/kernel/mpparse_32.c b/arch/x86/kernel/mpparse_32.c index febd69dbbee9..15dd87110298 100644 --- a/arch/x86/kernel/mpparse_32.c +++ b/arch/x86/kernel/mpparse_32.c | |||
@@ -98,6 +98,7 @@ static int __init mpf_checksum(unsigned char *mp, int len) | |||
98 | return sum & 0xFF; | 98 | return sum & 0xFF; |
99 | } | 99 | } |
100 | 100 | ||
101 | #ifdef CONFIG_X86_NUMAQ | ||
101 | /* | 102 | /* |
102 | * Have to match translation table entries to main table entries by counter | 103 | * Have to match translation table entries to main table entries by counter |
103 | * hence the mpc_record variable .... can't see a less disgusting way of | 104 | * hence the mpc_record variable .... can't see a less disgusting way of |
@@ -106,6 +107,7 @@ static int __init mpf_checksum(unsigned char *mp, int len) | |||
106 | 107 | ||
107 | static int mpc_record; | 108 | static int mpc_record; |
108 | static struct mpc_config_translation *translation_table[MAX_MPC_ENTRY] __cpuinitdata; | 109 | static struct mpc_config_translation *translation_table[MAX_MPC_ENTRY] __cpuinitdata; |
110 | #endif | ||
109 | 111 | ||
110 | static void __cpuinit MP_processor_info (struct mpc_config_processor *m) | 112 | static void __cpuinit MP_processor_info (struct mpc_config_processor *m) |
111 | { | 113 | { |
@@ -475,7 +477,9 @@ static int __init smp_read_mpc(struct mp_config_table *mpc) | |||
475 | /* | 477 | /* |
476 | * Now process the configuration blocks. | 478 | * Now process the configuration blocks. |
477 | */ | 479 | */ |
480 | #ifdef CONFIG_X86_NUMAQ | ||
478 | mpc_record = 0; | 481 | mpc_record = 0; |
482 | #endif | ||
479 | while (count < mpc->mpc_length) { | 483 | while (count < mpc->mpc_length) { |
480 | switch(*mpt) { | 484 | switch(*mpt) { |
481 | case MP_PROCESSOR: | 485 | case MP_PROCESSOR: |
@@ -532,7 +536,9 @@ static int __init smp_read_mpc(struct mp_config_table *mpc) | |||
532 | break; | 536 | break; |
533 | } | 537 | } |
534 | } | 538 | } |
539 | #ifdef CONFIG_X86_NUMAQ | ||
535 | ++mpc_record; | 540 | ++mpc_record; |
541 | #endif | ||
536 | } | 542 | } |
537 | setup_apic_routing(); | 543 | setup_apic_routing(); |
538 | if (!num_processors) | 544 | if (!num_processors) |
diff --git a/include/asm-x86/genapic_32.h b/include/asm-x86/genapic_32.h index 5a1b68ac3ca9..b501ae7809ba 100644 --- a/include/asm-x86/genapic_32.h +++ b/include/asm-x86/genapic_32.h | |||
@@ -14,7 +14,6 @@ | |||
14 | * Copyright 2003 Andi Kleen, SuSE Labs. | 14 | * Copyright 2003 Andi Kleen, SuSE Labs. |
15 | */ | 15 | */ |
16 | 16 | ||
17 | struct mpc_config_translation; | ||
18 | struct mpc_config_bus; | 17 | struct mpc_config_bus; |
19 | struct mp_config_table; | 18 | struct mp_config_table; |
20 | struct mpc_config_processor; | 19 | struct mpc_config_processor; |
diff --git a/include/asm-x86/mach-numaq/mach_apic.h b/include/asm-x86/mach-numaq/mach_apic.h index 3b637fac890b..75a56e5afbe7 100644 --- a/include/asm-x86/mach-numaq/mach_apic.h +++ b/include/asm-x86/mach-numaq/mach_apic.h | |||
@@ -95,6 +95,16 @@ static inline physid_mask_t apicid_to_cpu_present(int logical_apicid) | |||
95 | return physid_mask_of_physid(cpu + 4*node); | 95 | return physid_mask_of_physid(cpu + 4*node); |
96 | } | 96 | } |
97 | 97 | ||
98 | struct mpc_config_translation { | ||
99 | unsigned char mpc_type; | ||
100 | unsigned char trans_len; | ||
101 | unsigned char trans_type; | ||
102 | unsigned char trans_quad; | ||
103 | unsigned char trans_global; | ||
104 | unsigned char trans_local; | ||
105 | unsigned short trans_reserved; | ||
106 | }; | ||
107 | |||
98 | static inline int mpc_apic_id(struct mpc_config_processor *m, | 108 | static inline int mpc_apic_id(struct mpc_config_processor *m, |
99 | struct mpc_config_translation *translation_record) | 109 | struct mpc_config_translation *translation_record) |
100 | { | 110 | { |
diff --git a/include/asm-x86/mpspec_def.h b/include/asm-x86/mpspec_def.h index 3504617fe648..1f35691b4f7c 100644 --- a/include/asm-x86/mpspec_def.h +++ b/include/asm-x86/mpspec_def.h | |||
@@ -166,17 +166,6 @@ struct mp_config_oemtable | |||
166 | char mpc_oem[8]; | 166 | char mpc_oem[8]; |
167 | }; | 167 | }; |
168 | 168 | ||
169 | struct mpc_config_translation | ||
170 | { | ||
171 | unsigned char mpc_type; | ||
172 | unsigned char trans_len; | ||
173 | unsigned char trans_type; | ||
174 | unsigned char trans_quad; | ||
175 | unsigned char trans_global; | ||
176 | unsigned char trans_local; | ||
177 | unsigned short trans_reserved; | ||
178 | }; | ||
179 | |||
180 | /* | 169 | /* |
181 | * Default configurations | 170 | * Default configurations |
182 | * | 171 | * |