summaryrefslogtreecommitdiff
path: root/src/drivers/amd/agesa
diff options
context:
space:
mode:
authorKyösti Mälkki <kyosti.malkki@gmail.com>2019-12-15 21:37:38 +0200
committerKyösti Mälkki <kyosti.malkki@gmail.com>2019-12-20 15:47:39 +0000
commitfedaac84da5bcfd035e0e348150db8cf3d800726 (patch)
treea60bb306e8539a6bdad743e5a381129e011c20b0 /src/drivers/amd/agesa
parentfa0df7d316fc9b4be825b7ad60ada844660202c6 (diff)
AGESA,binaryPI: Enable lapic early for udelay()
Change-Id: I7200ac0256748d9372fc39be27b86d1c93b38321 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/37756 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Michał Żygowski <michal.zygowski@3mdeb.com> Reviewed-by: Angel Pons <th3fanbus@gmail.com> Reviewed-by: HAOUAS Elyes <ehaouas@noos.fr>
Diffstat (limited to 'src/drivers/amd/agesa')
-rw-r--r--src/drivers/amd/agesa/bootblock.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/drivers/amd/agesa/bootblock.c b/src/drivers/amd/agesa/bootblock.c
index 3763b98a3a..91fcc6b994 100644
--- a/src/drivers/amd/agesa/bootblock.c
+++ b/src/drivers/amd/agesa/bootblock.c
@@ -18,6 +18,7 @@
#include <amdblocks/biosram.h>
#include <cpu/amd/msr.h>
#include <cpu/x86/mtrr.h>
+#include <cpu/x86/lapic.h>
#define EARLY_VMTRR_FLASH 6
@@ -33,6 +34,9 @@ asmlinkage void bootblock_c_entry(uint64_t base_timestamp)
enable_pci_mmconf();
set_early_mtrrs();
+ if (CONFIG(UDELAY_LAPIC))
+ enable_lapic();
+
bootblock_main_with_basetime(base_timestamp);
}
@@ -41,6 +45,9 @@ asmlinkage void ap_bootblock_c_entry(void)
enable_pci_mmconf();
set_early_mtrrs();
+ if (CONFIG(UDELAY_LAPIC))
+ enable_lapic();
+
void (*ap_romstage_entry)(void) = get_ap_entry_ptr();
ap_romstage_entry(); /* execution does not return */
halt();