[PATCH RFC 6/6] bcm283x: debug_ll: add Raspberry Pi 5 UART support

Andrei Lalaev andrey.lalaev at gmail.com
Tue Sep 1 08:13:01 PDT 2026


This commit adds support for low-level debugging using UART debug port
on Raspberry Pi 5.

Signed-off-by: Andrei Lalaev <andrey.lalaev at gmail.com>
---
 common/Kconfig.debug_ll         |  8 ++++++++
 include/mach/bcm283x/debug_ll.h | 10 ++++++++++
 include/mach/bcm283x/platform.h |  1 +
 3 files changed, 19 insertions(+)

diff --git a/common/Kconfig.debug_ll b/common/Kconfig.debug_ll
index 6126431692eb..c6091979bfa3 100644
--- a/common/Kconfig.debug_ll
+++ b/common/Kconfig.debug_ll
@@ -301,6 +301,14 @@ config DEBUG_RPI4_MINI_UART
 	  Say Y here if you want low-level debugging support on
 	  RaspberryPi 4 board mini UART.
 
+config DEBUG_RPI5_UART
+	bool "RaspberryPi 5 PL011 UART"
+	depends on ARCH_BCM283X
+	select DEBUG_BCM283X_UART
+	help
+	  Say Y here if you want low-level debugging support on
+	  RaspberryPi 5 boards.
+
 config DEBUG_ZYNQ_UART
 	bool "Zynq debug UART"
 	depends on ARCH_ZYNQ
diff --git a/include/mach/bcm283x/debug_ll.h b/include/mach/bcm283x/debug_ll.h
index 3f2d5ddc9857..7562fe977e87 100644
--- a/include/mach/bcm283x/debug_ll.h
+++ b/include/mach/bcm283x/debug_ll.h
@@ -113,6 +113,16 @@ static inline void PUTC_LL(char c)
 	debug_ll_ns16550_putc(base, c);
 }
 
+#elif defined CONFIG_DEBUG_RPI5_UART
+
+static inline void debug_ll_init(void)
+{
+	/* Configured by ROM */
+}
+
+#define DEBUG_LL_UART_ADDR BCM2712_PL011_BASE
+#include <debug_ll/pl011.h>
+
 #else
 
 static inline void debug_ll_init(void)
diff --git a/include/mach/bcm283x/platform.h b/include/mach/bcm283x/platform.h
index 54d8b38bd8ed..a25bde84ee16 100644
--- a/include/mach/bcm283x/platform.h
+++ b/include/mach/bcm283x/platform.h
@@ -36,6 +36,7 @@
 #define BCM2835_MINIUART_BASE 0x20215040
 #define BCM2836_MINIUART_BASE 0x3f215040UL
 #define BCM2711_MINIUART_BASE 0xfe215040UL
+#define BCM2712_PL011_BASE 0x107d001000UL
 
 #endif
 

-- 
2.55.0




More information about the barebox mailing list