diff options
author | Maxim Polyakov <max.senia.poliak@gmail.com> | 2020-04-26 20:56:50 +0300 |
---|---|---|
committer | Andrey Petrov <andrey.petrov@gmail.com> | 2020-05-01 21:39:21 +0000 |
commit | 89d2aa0cdc43a85258ff6b6ca2c781339081025a (patch) | |
tree | 1e46483de66fd37ae184825e0b79325efaf23153 /src/mainboard/ocp/tiogapass/bootblock.c | |
parent | ed7d91d2579ea9a8eb6b62972ad7beeb2f136d8a (diff) |
mb/tiogapass: use common driver to configure GPIO
According to changes in the soc/xeon_sp code [1,2], server motherboards
with Lewisburg PCH can use the soc/intel/common/gpio driver to configure
GPIO controller. This patch adds pads configuration map, which has the
format required by the GPIO driver. The data for this was taken from the
inteltool register dump with AMI firmware. The gpio.h file with pad
configuration was generated automatically using the util/intelp2m [3]:
./intelp2m -raw -p lbg -file tiogapass/vendorbios/inteltool_gpio.log
[1] https: //review.coreboot.org/c/coreboot/+/39425
[2] https: //review.coreboot.org/c/coreboot/+/39428
[3] https: //review.coreboot.org/c/coreboot/+/35643
Change-Id: I818d040fa33f3e7b94b73c9bbbafca5df424616d
Signed-off-by: Maxim Polyakov <max.senia.poliak@gmail.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/39427
Reviewed-by: Andrey Petrov <andrey.petrov@gmail.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/mainboard/ocp/tiogapass/bootblock.c')
-rw-r--r-- | src/mainboard/ocp/tiogapass/bootblock.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mainboard/ocp/tiogapass/bootblock.c b/src/mainboard/ocp/tiogapass/bootblock.c index 67808ef72a..dbb3b6a93f 100644 --- a/src/mainboard/ocp/tiogapass/bootblock.c +++ b/src/mainboard/ocp/tiogapass/bootblock.c @@ -10,6 +10,7 @@ #include <soc/pcr_ids.h> #include <superio/aspeed/ast2400/ast2400.h> #include <superio/aspeed/common/aspeed.h> +#include "gpio.h" /* these are defined in intelblocks/lpc_lib.h but we can't use them yet */ #define PCR_DMI_LPCIOD 0x2770 @@ -53,6 +54,9 @@ static uint8_t com_to_ast_sio(uint8_t com) void bootblock_mainboard_early_init(void) { + /* pre-configure Lewisburg PCH GPIO pads */ + gpio_configure_pads(gpio_table, ARRAY_SIZE(gpio_table)); + /* Open IO windows */ enable_espi_lpc_io_windows(); |