diff mbox

[U-Boot,8/8] x86: baytrail: acpi: Fix I/O APIC ID in the MADT table

Message ID 1464166138-14975-9-git-send-email-bmeng.cn@gmail.com
State Accepted
Commit d3d664725b4a05cf32d905ff806b44bb01fa61c0
Delegated to: Bin Meng
Headers show

Commit Message

Bin Meng May 25, 2016, 8:48 a.m. UTC
So far this is hardcoded to 2, but it should really be read
from the I/O APIC register.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>

---

 arch/x86/cpu/baytrail/acpi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Simon Glass May 25, 2016, 11:17 p.m. UTC | #1
On 25 May 2016 at 02:48, Bin Meng <bmeng.cn@gmail.com> wrote:
>
> So far this is hardcoded to 2, but it should really be read
> from the I/O APIC register.
>
> Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
>
> ---
>
>  arch/x86/cpu/baytrail/acpi.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)


Reviewed-by: Simon Glass <sjg@chromium.org>
diff mbox

Patch

diff --git a/arch/x86/cpu/baytrail/acpi.c b/arch/x86/cpu/baytrail/acpi.c
index 1d54f7d..5ee4868 100644
--- a/arch/x86/cpu/baytrail/acpi.c
+++ b/arch/x86/cpu/baytrail/acpi.c
@@ -155,7 +155,7 @@  u32 acpi_fill_madt(u32 current)
 	current += acpi_create_madt_lapics(current);
 
 	current += acpi_create_madt_ioapic((struct acpi_madt_ioapic *)current,
-			2, IO_APIC_ADDR, 0);
+			io_apic_read(IO_APIC_ID) >> 24, IO_APIC_ADDR, 0);
 
 	current += acpi_create_madt_irq_overrides(current);