diff --git a/src/mainboard/google/guybrush/verstage.c b/src/mainboard/google/guybrush/verstage.c index 42967290b4..904ae2f64c 100644 --- a/src/mainboard/google/guybrush/verstage.c +++ b/src/mainboard/google/guybrush/verstage.c @@ -1,6 +1,8 @@ /* SPDX-License-Identifier: GPL-2.0-or-later */ +#include #include +#include #include #include @@ -18,4 +20,21 @@ static void setup_gpio(void) void verstage_mainboard_early_init(void) { setup_gpio(); + + /* + * TODO : Make common function in cezanne code and just call it + * when PCI access is fixed in the PSP (b/186602472). + * For now the PSP doesn't configure LPC so it should be fine. + */ + if (CONFIG(VBOOT_STARTS_BEFORE_BOOTBLOCK)) { + uint32_t dword; + printk(BIOS_DEBUG, "Verstage configure eSPI\n"); + dword = pm_io_read32(0x90); + dword |= 1 << 16; + pm_io_write32(0x90, dword); + + dword = pm_io_read32(0x74); + dword |= 3 << 10; + pm_io_write32(0x74, dword); + } }