]> git.baikalelectronics.ru Git - kernel.git/commit
ACPI / SRAT: fix SRAT parsing order with both LAPIC and X2APIC present
authorLukasz Anaczkowski <lukasz.anaczkowski@intel.com>
Thu, 21 Apr 2016 09:29:00 +0000 (11:29 +0200)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 21 Apr 2016 20:13:03 +0000 (22:13 +0200)
commita6604bb34107401105f42b84416aa35037a6a2d0
treea92c009c3afe4b213ccb0da65cdd231dfcd7aff2
parent29117ef53592e44617a5e92e9234f15273b7ba82
ACPI / SRAT: fix SRAT parsing order with both LAPIC and X2APIC present

SRAT maps APIC ID to proximity domains ids (PXM). Mapping from PXM to
NUMA node ids is based on order of entries in SRAT table.
SRAT table has just LAPIC entires or mix of LAPIC and X2APIC entries.
As long as there are only LAPIC entires, mapping from proximity domain
id to NUMA node id is as assumed by BIOS. However, once APIC entries are
mixed, X2APIC entries would be first mapped which causes unexpected NUMA
node mapping.

To fix that, change parsing to check each entry against both LAPIC and
X2APIC so mapping is in the SRAT/PXM order.

This is supplemental change to the fix made by commit 1b4fe39ba67
(Handle apic/x2apic entries in MADT in correct order) and using the
mechanism introduced by fd3c5d0 (ACPI / tables: Add acpi_subtable_proc
to ACPI table parsers).

Fixes: 1b4fe39ba67 (Handle apic/x2apic entries in MADT in correct order)
Signed-off-by: Lukasz Anaczkowski <lukasz.anaczkowski@intel.com>
[ rjw : Subject & changelog ]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/numa.c