aboutsummaryrefslogtreecommitdiff
path: root/src/arch/x86/cpu.c
diff options
context:
space:
mode:
authorFurquan Shaikh <furquan@google.com>2020-04-30 21:27:47 -0700
committerFelix Held <felix-coreboot@felixheld.de>2020-05-02 12:11:41 +0000
commitb1859a6687553900337c9ace092517e921e95e3b (patch)
tree0f5c1a7eb78485b182ce0c3e6991a1d50b37e228 /src/arch/x86/cpu.c
parenta268aac9e5b79dcd96ab3411413f4385bfecfe5e (diff)
cpu: Add a helper function cpu_get_lapic_addr
This change adds a helper function cpu_get_lapic_addr() that returns LOCAL_APIC_ADDR for x86. It also adds a weak default implementation which returns 0 if platform does not support LAPIC. This is being done in preparation to move all ACPI table support in coreboot out of arch/x86. BUG=b:155428745 Change-Id: I4d9c50ee46804164712aaa22be1b434f800871ec Signed-off-by: Furquan Shaikh <furquan@google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/40929 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Aaron Durbin <adurbin@chromium.org> Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
Diffstat (limited to 'src/arch/x86/cpu.c')
-rw-r--r--src/arch/x86/cpu.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/arch/x86/cpu.c b/src/arch/x86/cpu.c
index 1ee8fb32c3..b52376885f 100644
--- a/src/arch/x86/cpu.c
+++ b/src/arch/x86/cpu.c
@@ -354,3 +354,8 @@ int cpu_index(void)
}
return -1;
}
+
+uintptr_t cpu_get_lapic_addr(void)
+{
+ return LOCAL_APIC_ADDR;
+}