summaryrefslogtreecommitdiff
path: root/src/mainboard/google/guybrush/variants/baseboard
diff options
context:
space:
mode:
authorMathew King <mathewk@chromium.org>2021-03-11 08:25:52 -0700
committerFelix Held <felix-coreboot@felixheld.de>2021-03-13 01:31:12 +0000
commitd490afbe04a41f380ab79dfe92f28dda74ab52a7 (patch)
tree77e7ea950457b6a08c415be66d8a6e8c34430118 /src/mainboard/google/guybrush/variants/baseboard
parent7a8108deb9dab63aa77447f35ba0fe8201eca266 (diff)
mb/google/guybrush: Configure early GPIOs in earliest stage
Configure early GPIOs in verstage if it is run in PSP otherwise configure them in bootblock. BUG=b:181961514, b:180721208 TEST=builds Signed-off-by: Mathew King <mathewk@chromium.org> Change-Id: Ib9410089592776ffe198901f2de914fd04bdbade Reviewed-on: https://review.coreboot.org/c/coreboot/+/51348 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Martin Roth <martinroth@google.com>
Diffstat (limited to 'src/mainboard/google/guybrush/variants/baseboard')
-rw-r--r--src/mainboard/google/guybrush/variants/baseboard/Makefile.inc2
-rw-r--r--src/mainboard/google/guybrush/variants/baseboard/gpio.c12
-rw-r--r--src/mainboard/google/guybrush/variants/baseboard/include/baseboard/variants.h4
3 files changed, 10 insertions, 8 deletions
diff --git a/src/mainboard/google/guybrush/variants/baseboard/Makefile.inc b/src/mainboard/google/guybrush/variants/baseboard/Makefile.inc
index 7c092e44c2..3b86b93aba 100644
--- a/src/mainboard/google/guybrush/variants/baseboard/Makefile.inc
+++ b/src/mainboard/google/guybrush/variants/baseboard/Makefile.inc
@@ -2,4 +2,6 @@ bootblock-y += gpio.c
ramstage-y += gpio.c
+verstage-y += gpio.c
+
smm-y += gpio.c
diff --git a/src/mainboard/google/guybrush/variants/baseboard/gpio.c b/src/mainboard/google/guybrush/variants/baseboard/gpio.c
index 68c7d290ef..3e9d88a468 100644
--- a/src/mainboard/google/guybrush/variants/baseboard/gpio.c
+++ b/src/mainboard/google/guybrush/variants/baseboard/gpio.c
@@ -163,9 +163,9 @@ static const struct soc_amd_gpio base_gpio_table[] = {
PAD_NF(GPIO_148, I2C1_SDA, PULL_NONE),
};
-/* Early GPIO configuration in bootblock */
-static const struct soc_amd_gpio bootblock_gpio_table[] = {
- /* TODO: Fill bootblock gpio configuration */
+/* Early GPIO configuration */
+static const struct soc_amd_gpio early_gpio_table[] = {
+ /* TODO: Fill early gpio configuration */
};
/* GPIO configuration for sleep */
@@ -184,10 +184,10 @@ const struct soc_amd_gpio *__weak variant_override_gpio_table(size_t *size)
return NULL;
}
-const struct soc_amd_gpio *__weak variant_bootblock_gpio_table(size_t *size)
+const struct soc_amd_gpio *__weak variant_early_gpio_table(size_t *size)
{
- *size = ARRAY_SIZE(bootblock_gpio_table);
- return bootblock_gpio_table;
+ *size = ARRAY_SIZE(early_gpio_table);
+ return early_gpio_table;
}
const __weak struct soc_amd_gpio *variant_sleep_gpio_table(size_t *size)
diff --git a/src/mainboard/google/guybrush/variants/baseboard/include/baseboard/variants.h b/src/mainboard/google/guybrush/variants/baseboard/include/baseboard/variants.h
index 91a2f147d2..dccaed0e2c 100644
--- a/src/mainboard/google/guybrush/variants/baseboard/include/baseboard/variants.h
+++ b/src/mainboard/google/guybrush/variants/baseboard/include/baseboard/variants.h
@@ -18,8 +18,8 @@ const struct soc_amd_gpio *variant_base_gpio_table(size_t *size);
*/
const struct soc_amd_gpio *variant_override_gpio_table(size_t *size);
-/* This function provides GPIO init in bootblock. */
-const struct soc_amd_gpio *variant_bootblock_gpio_table(size_t *size);
+/* This function provides early GPIO init in bootblock or psp. */
+const struct soc_amd_gpio *variant_early_gpio_table(size_t *size);
/* This function provides GPIO settings before entering sleep. */
const struct soc_amd_gpio *variant_sleep_gpio_table(size_t *size);