Revert "ACPI / processor: Make it possible to get APIC ID via GIC"
Revert commitdf86f5df79
(ACPI / processor: Make it possible to get APIC ID via GIC). APIC ID refers the hardware ID of the CPU, which means MPIDR on ARM/ARM64, but in ACPI 5.0, GIC ID feild in GIC structure have no explicit definition and may not refer to the MPIDR. Commitdf86f5df79
assumed that gic->gic_id as MPIDR which may not be the case, so revert it until the explicit definition of GIC structure is ready. Signed-off-by: Hanjun Guo <hanjun.guo@linaro.org> [rjw: Changelog] Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:
parent
38953d3945
commit
3e9eac50cd
1 changed files with 0 additions and 27 deletions
|
@ -71,28 +71,6 @@ static int map_lsapic_id(struct acpi_subtable_header *entry,
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int map_gic_id(struct acpi_subtable_header *entry,
|
|
||||||
int device_declaration, u32 acpi_id, int *apic_id)
|
|
||||||
{
|
|
||||||
struct acpi_madt_generic_interrupt *gic =
|
|
||||||
(struct acpi_madt_generic_interrupt *)entry;
|
|
||||||
|
|
||||||
if (!(gic->flags & ACPI_MADT_ENABLED))
|
|
||||||
return -ENODEV;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* In the GIC interrupt model, logical processors are
|
|
||||||
* required to have a Processor Device object in the DSDT,
|
|
||||||
* so we should check device_declaration here
|
|
||||||
*/
|
|
||||||
if (device_declaration && (gic->uid == acpi_id)) {
|
|
||||||
*apic_id = gic->gic_id;
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
return -EINVAL;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int map_madt_entry(int type, u32 acpi_id)
|
static int map_madt_entry(int type, u32 acpi_id)
|
||||||
{
|
{
|
||||||
unsigned long madt_end, entry;
|
unsigned long madt_end, entry;
|
||||||
|
@ -128,9 +106,6 @@ static int map_madt_entry(int type, u32 acpi_id)
|
||||||
} else if (header->type == ACPI_MADT_TYPE_LOCAL_SAPIC) {
|
} else if (header->type == ACPI_MADT_TYPE_LOCAL_SAPIC) {
|
||||||
if (!map_lsapic_id(header, type, acpi_id, &apic_id))
|
if (!map_lsapic_id(header, type, acpi_id, &apic_id))
|
||||||
break;
|
break;
|
||||||
} else if (header->type == ACPI_MADT_TYPE_GENERIC_INTERRUPT) {
|
|
||||||
if (!map_gic_id(header, type, acpi_id, &apic_id))
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
entry += header->length;
|
entry += header->length;
|
||||||
}
|
}
|
||||||
|
@ -161,8 +136,6 @@ static int map_mat_entry(acpi_handle handle, int type, u32 acpi_id)
|
||||||
map_lapic_id(header, acpi_id, &apic_id);
|
map_lapic_id(header, acpi_id, &apic_id);
|
||||||
} else if (header->type == ACPI_MADT_TYPE_LOCAL_SAPIC) {
|
} else if (header->type == ACPI_MADT_TYPE_LOCAL_SAPIC) {
|
||||||
map_lsapic_id(header, type, acpi_id, &apic_id);
|
map_lsapic_id(header, type, acpi_id, &apic_id);
|
||||||
} else if (header->type == ACPI_MADT_TYPE_GENERIC_INTERRUPT) {
|
|
||||||
map_gic_id(header, type, acpi_id, &apic_id);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
exit:
|
exit:
|
||||||
|
|
Loading…
Add table
Reference in a new issue