aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86')
-rw-r--r--arch/x86/kernel/apic/summit_32.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/arch/x86/kernel/apic/summit_32.c b/arch/x86/kernel/apic/summit_32.c
index cfe7b09015d8..d02f4385707c 100644
--- a/arch/x86/kernel/apic/summit_32.c
+++ b/arch/x86/kernel/apic/summit_32.c
@@ -303,12 +303,10 @@ static inline unsigned int summit_cpu_mask_to_apicid(const cpumask_t *cpumask)
303 int cpu; 303 int cpu;
304 304
305 num_bits_set = cpus_weight(*cpumask); 305 num_bits_set = cpus_weight(*cpumask);
306 /* Return id to all */
307 if (num_bits_set >= nr_cpu_ids) 306 if (num_bits_set >= nr_cpu_ids)
308 return 0xFF; 307 return BAD_APICID;
309 /* 308 /*
310 * The cpus in the mask must all be on the apic cluster. If are not 309 * The cpus in the mask must all be on the apic cluster.
311 * on the same apicid cluster return default value of target_cpus():
312 */ 310 */
313 cpu = first_cpu(*cpumask); 311 cpu = first_cpu(*cpumask);
314 apicid = summit_cpu_to_logical_apicid(cpu); 312 apicid = summit_cpu_to_logical_apicid(cpu);
@@ -318,9 +316,9 @@ static inline unsigned int summit_cpu_mask_to_apicid(const cpumask_t *cpumask)
318 int new_apicid = summit_cpu_to_logical_apicid(cpu); 316 int new_apicid = summit_cpu_to_logical_apicid(cpu);
319 317
320 if (APIC_CLUSTER(apicid) != APIC_CLUSTER(new_apicid)) { 318 if (APIC_CLUSTER(apicid) != APIC_CLUSTER(new_apicid)) {
321 printk ("%s: Not a valid mask!\n", __func__); 319 printk("%s: Not a valid mask!\n", __func__);
322 320
323 return 0xFF; 321 return BAD_APICID;
324 } 322 }
325 apicid = apicid | new_apicid; 323 apicid = apicid | new_apicid;
326 cpus_found++; 324 cpus_found++;