|
@@ -200,7 +200,7 @@ acpi_parse_x2apic(struct acpi_subtable_header *header, const unsigned long end)
|
|
|
{
|
|
|
struct acpi_madt_local_x2apic *processor = NULL;
|
|
|
#ifdef CONFIG_X86_X2APIC
|
|
|
- int apic_id;
|
|
|
+ u32 apic_id;
|
|
|
u8 enabled;
|
|
|
#endif
|
|
|
|
|
@@ -222,10 +222,13 @@ acpi_parse_x2apic(struct acpi_subtable_header *header, const unsigned long end)
|
|
|
* to not preallocating memory for all NR_CPUS
|
|
|
* when we use CPU hotplug.
|
|
|
*/
|
|
|
- if (!apic->apic_id_valid(apic_id) && enabled)
|
|
|
- printk(KERN_WARNING PREFIX "x2apic entry ignored\n");
|
|
|
- else
|
|
|
- acpi_register_lapic(apic_id, processor->uid, enabled);
|
|
|
+ if (!apic->apic_id_valid(apic_id)) {
|
|
|
+ if (enabled)
|
|
|
+ pr_warn(PREFIX "x2apic entry ignored\n");
|
|
|
+ return 0;
|
|
|
+ }
|
|
|
+
|
|
|
+ acpi_register_lapic(apic_id, processor->uid, enabled);
|
|
|
#else
|
|
|
printk(KERN_WARNING PREFIX "x2apic entry ignored\n");
|
|
|
#endif
|