diff --git a/src/mainboard/google/herobrine/mainboard.c b/src/mainboard/google/herobrine/mainboard.c index 6f8d19d8d1..55b1c5e575 100644 --- a/src/mainboard/google/herobrine/mainboard.c +++ b/src/mainboard/google/herobrine/mainboard.c @@ -9,6 +9,9 @@ #include #include #include +#include +#include +#include static void configure_sdhci(void) { @@ -25,6 +28,26 @@ static void mainboard_init(struct device *dev) /* Configure clock for SD card */ clock_configure_sdcc(2, 50 * MHz); configure_sdhci(); + + /* + * When coreboot firmware disables serial output, + * we still need to load console UART QUP FW for OS. + */ + if (!CONFIG(CONSOLE_SERIAL)) + qupv3_se_fw_load_and_init(QUPV3_0_SE5, SE_PROTOCOL_UART, FIFO); + + qupv3_se_fw_load_and_init(QUPV3_1_SE5, SE_PROTOCOL_I2C, MIXED); /* Touch I2C */ + qupv3_se_fw_load_and_init(QUPV3_0_SE7, SE_PROTOCOL_UART, FIFO); /* BT UART */ + +#if CONFIG(BOARD_GOOGLE_HEROBRINE) + qupv3_se_fw_load_and_init(QUPV3_0_SE0, SE_PROTOCOL_I2C, MIXED); /* Audio I2C */ + qupv3_se_fw_load_and_init(QUPV3_0_SE1, SE_PROTOCOL_I2C, MIXED); /* Trackpad I2C */ + qupv3_se_fw_load_and_init(QUPV3_1_SE3, SE_PROTOCOL_SPI, MIXED); /* Fingerprint SPI */ +#elif CONFIG(BOARD_GOOGLE_PIGLIN) + qupv3_se_fw_load_and_init(QUPV3_0_SE1, SE_PROTOCOL_I2C, GSI); /* APPS I2C */ + qupv3_se_fw_load_and_init(QUPV3_1_SE4, SE_PROTOCOL_SPI, MIXED); /* ESIM SPI */ + qupv3_se_fw_load_and_init(QUPV3_1_SE6, SE_PROTOCOL_SPI, MIXED); /* Fingerprint SPI */ +#endif } static void mainboard_enable(struct device *dev)