aboutsummaryrefslogtreecommitdiff
path: root/src/soc/amd/cezanne/early_fch.c
diff options
context:
space:
mode:
authorFelix Held <felix-coreboot@felixheld.de>2021-01-13 03:06:21 +0100
committerFelix Held <felix-coreboot@felixheld.de>2021-01-14 15:41:42 +0000
commit8a3d4d5ec6260a2db9cfda954860ed525bb67134 (patch)
treeb9d7574fbdd5d057547e4689017dd922701d70d2 /src/soc/amd/cezanne/early_fch.c
parent91ef92525d8a9a0e83be8d91eb5e83b1cab58008 (diff)
soc/amd/cezanne: add console UART support
Change-Id: I1a01cc745c7049dc672bca12df5c6b764ac9b907 Signed-off-by: Felix Held <felix-coreboot@felixheld.de> Reviewed-on: https://review.coreboot.org/c/coreboot/+/49376 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Diffstat (limited to 'src/soc/amd/cezanne/early_fch.c')
-rw-r--r--src/soc/amd/cezanne/early_fch.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/soc/amd/cezanne/early_fch.c b/src/soc/amd/cezanne/early_fch.c
index 6616d075b9..b6681e32e3 100644
--- a/src/soc/amd/cezanne/early_fch.c
+++ b/src/soc/amd/cezanne/early_fch.c
@@ -4,6 +4,7 @@
#include <amdblocks/smbus.h>
#include <console/console.h>
#include <soc/southbridge.h>
+#include <soc/uart.h>
/* Before console init */
void fch_pre_init(void)
@@ -12,6 +13,15 @@ void fch_pre_init(void)
fch_smbus_init();
fch_enable_cf9_io();
fch_enable_legacy_io();
+
+ /*
+ * On reset Range_0 defaults to enabled. We want to start with a clean
+ * slate to not have things unexpectedly enabled.
+ */
+ clear_uart_legacy_config();
+
+ if (CONFIG(AMD_SOC_CONSOLE_UART))
+ set_uart_config(CONFIG_UART_FOR_CONSOLE);
}
/* After console init */