From 4dc6646f5351398eeee6a944c358fcb102f75cf4 Mon Sep 17 00:00:00 2001 From: Furquan Shaikh Date: Fri, 27 Jul 2018 14:14:27 -0700 Subject: mb/google/octopus: Perform EC init before bootblock gpio configuration A variant might talk to the EC to get board id in order to identify the right GPIO configuration. Thus it is important to ensure that the LPC IO windows are configured before this. This change moves the call to perform EC init before configuring bootblock GPIOs. BUG=b:111933657 TEST=Verified that reading board id does not fail on phaser. Change-Id: Ic23c6fd7597a314e0b6421be39ccc0b1dfb46567 Signed-off-by: Furquan Shaikh Reviewed-on: https://review.coreboot.org/27671 Reviewed-by: Justin TerAvest Tested-by: build bot (Jenkins) --- src/mainboard/google/octopus/bootblock.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src/mainboard') diff --git a/src/mainboard/google/octopus/bootblock.c b/src/mainboard/google/octopus/bootblock.c index 6826e5db9b..0c239db369 100644 --- a/src/mainboard/google/octopus/bootblock.c +++ b/src/mainboard/google/octopus/bootblock.c @@ -25,7 +25,14 @@ void bootblock_mainboard_init(void) size_t num; lpc_configure_pads(); + + /* + * Perform EC init before configuring GPIOs. This is because variant + * might talk to the EC to get board id and hence it will require EC + * init to have already performed. + */ + mainboard_ec_init(); + pads = variant_early_gpio_table(&num); gpio_configure_pads(pads, num); - mainboard_ec_init(); } -- cgit v1.2.3