[U-Boot] [PATCH 1/4] serial: ns16550: da8xx (freon/primus) is not omap-like
Matthijs van Duin
matthijsvanduin at gmail.com
Mon Jan 8 12:50:59 UTC 2018
These are SoCs in the lineage of TI C6x DSPs, and as such have the same
uart as TI Keystone SoCs.
Signed-off-by: Matthijs van Duin <matthijsvanduin at gmail.com>
---
drivers/serial/ns16550.c | 8 ++++----
include/ns16550.h | 2 +-
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/drivers/serial/ns16550.c b/drivers/serial/ns16550.c
index c702304e79bd..9cec58c887c8 100644
--- a/drivers/serial/ns16550.c
+++ b/drivers/serial/ns16550.c
@@ -36,7 +36,7 @@ DECLARE_GLOBAL_DATA_PTR;
#endif
#endif /* !CONFIG_DM_SERIAL */
-#if defined(CONFIG_SOC_KEYSTONE)
+#if defined(CONFIG_SOC_KEYSTONE) || defined(CONFIG_SOC_DA8XX)
#define UART_REG_VAL_PWREMU_MGMT_UART_DISABLE 0
#define UART_REG_VAL_PWREMU_MGMT_UART_ENABLE ((1 << 14) | (1 << 13) | (1 << 0))
#undef UART_MCRVAL
@@ -181,12 +181,12 @@ void NS16550_init(NS16550_t com_port, int baud_divisor)
serial_out(ns16550_getfcr(com_port), &com_port->fcr);
if (baud_divisor != -1)
NS16550_setbrg(com_port, baud_divisor);
-#if defined(CONFIG_ARCH_OMAP2PLUS) || defined(CONFIG_SOC_DA8XX)
+#if defined(CONFIG_ARCH_OMAP2PLUS)
/* /16 is proper to hit 115200 with 48MHz */
serial_out(0, &com_port->mdr1);
#endif
-#if defined(CONFIG_SOC_KEYSTONE)
- serial_out(UART_REG_VAL_PWREMU_MGMT_UART_ENABLE, &com_port->regC);
+#if defined(CONFIG_SOC_KEYSTONE) || defined(CONFIG_SOC_DA8XX)
+ serial_out(UART_REG_VAL_PWREMU_MGMT_UART_ENABLE, &com_port->pwr_mgmt);
#endif
}
diff --git a/include/ns16550.h b/include/ns16550.h
index 5fcbcd2e74e3..a988d297e144 100644
--- a/include/ns16550.h
+++ b/include/ns16550.h
@@ -71,7 +71,7 @@ struct NS16550 {
UART_REG(lsr); /* 5 */
UART_REG(msr); /* 6 */
UART_REG(spr); /* 7 */
-#ifdef CONFIG_SOC_DA8XX
+#if defined(CONFIG_SOC_KEYSTONE) || defined(CONFIG_SOC_DA8XX)
UART_REG(reg8); /* 8 */
UART_REG(reg9); /* 9 */
UART_REG(revid1); /* A */
--
2.11.0
More information about the U-Boot
mailing list