[PATCH v2 11/22] ARM: k3: add k3_debug_ll_init()
Sascha Hauer
s.hauer at pengutronix.de
Mon Jan 6 05:47:08 PST 2025
Add a function to initialize the ns16550 compatible UART for debug_ll.
Signed-off-by: Sascha Hauer <s.hauer at pengutronix.de>
---
include/mach/k3/debug_ll.h | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/include/mach/k3/debug_ll.h b/include/mach/k3/debug_ll.h
index 29bd4015ab..a37b50c726 100644
--- a/include/mach/k3/debug_ll.h
+++ b/include/mach/k3/debug_ll.h
@@ -33,6 +33,14 @@ static inline void debug_ll_init(void)
/* already configured */
}
+static inline void k3_debug_ll_init(void __iomem *base)
+{
+ debug_ll_ns16550_init(base, 26);
+
+ debug_ll_write_reg(base, 8, 0x07);
+ debug_ll_write_reg(base, 8, 0x00);
+}
+
static inline void PUTC_LL(int c)
{
void __iomem *base = (void *)K3_UART_BASE(K3_DEBUG_SOC,
--
2.39.5
More information about the barebox
mailing list