diff options
author | Tim Wawrzynczak <twawrzynczak@chromium.org> | 2019-04-16 15:21:09 -0600 |
---|---|---|
committer | Furquan Shaikh <furquan@google.com> | 2019-04-19 03:05:05 +0000 |
commit | 64a6bcaa4eb491170b4424f7d676f09854c2744a (patch) | |
tree | b9a59830e31d6ff7a70d6c7f3d2e62f1c39425e3 /src/mainboard/google/hatch/ramstage.c | |
parent | 395f1e328d284ed516fb3064c4d59f8810e677c6 (diff) |
kohaku: mb/hatch/gpio: Scrub Kohaku GPIOs.
Ensure Kohaku GPIO pins are configured correctly w/r/t Hatch. Implement the
base/override model for GPIOs (regular and early). The 'hatch' baseboard
contains the base GPIOs, and variants can override individual pads.
BUG=b:129707481
BRANCH=none
TEST=Compiles for all variants.
Change-Id: Ie5c83a0538d367ea11e9499f21cea41891d7a78e
Signed-off-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/32326
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Paul Fagerburg <pfagerburg@chromium.org>
Reviewed-by: Furquan Shaikh <furquan@google.com>
Diffstat (limited to 'src/mainboard/google/hatch/ramstage.c')
-rw-r--r-- | src/mainboard/google/hatch/ramstage.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/src/mainboard/google/hatch/ramstage.c b/src/mainboard/google/hatch/ramstage.c index 5824e66735..3436007252 100644 --- a/src/mainboard/google/hatch/ramstage.c +++ b/src/mainboard/google/hatch/ramstage.c @@ -23,11 +23,18 @@ void mainboard_silicon_init_params(FSP_S_CONFIG *params) { - const struct pad_config *gpio_table; - size_t num_gpios; + const struct pad_config *base_table; + const struct pad_config *override_table; + size_t base_gpios; + size_t override_gpios; - gpio_table = variant_gpio_table(&num_gpios); - cnl_configure_pads(gpio_table, num_gpios); + base_table = base_gpio_table(&base_gpios); + override_table = override_gpio_table(&override_gpios); + + gpio_configure_pads_with_override(base_table, + base_gpios, + override_table, + override_gpios); } static void mainboard_enable(struct device *dev) |