mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Lucas Stach <dev@lynxeye.de>
To: barebox@lists.infradead.org
Subject: [PATCH 2/3] ARM: vexpress: allow to select debug UART address
Date: Sun, 16 Aug 2020 23:42:41 +0200	[thread overview]
Message-ID: <20200816214242.137168-2-dev@lynxeye.de> (raw)
In-Reply-To: <20200816214242.137168-1-dev@lynxeye.de>

DEBUG_LL currently doesn't work on the Vexpress platform for multiple
reasons: the addresses defined in the header aren't the real UART base
addresses but only the bus base address, also the referenced MP define
is never set.

Add two options to allow the user to select the correct debug UART
address for both supported Vexpress platforms.

Signed-off-by: Lucas Stach <dev@lynxeye.de>
---
 arch/arm/mach-vexpress/include/mach/debug_ll.h | 11 +++++------
 common/Kconfig                                 | 15 +++++++++++++++
 2 files changed, 20 insertions(+), 6 deletions(-)

diff --git a/arch/arm/mach-vexpress/include/mach/debug_ll.h b/arch/arm/mach-vexpress/include/mach/debug_ll.h
index d59f68ea1973..a9c0d9850db8 100644
--- a/arch/arm/mach-vexpress/include/mach/debug_ll.h
+++ b/arch/arm/mach-vexpress/include/mach/debug_ll.h
@@ -10,13 +10,12 @@
 #include <linux/amba/serial.h>
 #include <io.h>
 
-#define DEBUG_LL_PHYS_BASE		0x10000000
-#define DEBUG_LL_PHYS_BASE_RS1		0x1c000000
+#ifdef CONFIG_DEBUG_VEXPRESS_CA9_UART
+#define DEBUG_LL_UART_ADDR 0x10009000
+#endif
 
-#ifdef MP
-#define DEBUG_LL_UART_ADDR DEBUG_LL_PHYS_BASE
-#else
-#define DEBUG_LL_UART_ADDR DEBUG_LL_PHYS_BASE_RS1
+#ifdef CONFIG_DEBUG_VEXPRESS_CA15_UART
+#define DEBUG_LL_UART_ADDR 0x1c090000
 #endif
 
 #include <debug_ll/pl011.h>
diff --git a/common/Kconfig b/common/Kconfig
index 658437f01c5e..09b36f6f7880 100644
--- a/common/Kconfig
+++ b/common/Kconfig
@@ -1287,6 +1287,21 @@ config DEBUG_RPI3_MINI_UART
 	help
 	  Say Y here if you want low-level debugging support on
 	  RaspberryPi 3 board mini UART.
+
+config DEBUG_VEXPRESS_CA9_UART
+	bool "Vexpress CA9 debug UART"
+	depends on ARCH_VEXPRESS
+	help
+	  Say Y here if you want low-level debugging support on the
+	  Cortex-A9 based Vexpress boards.
+
+config DEBUG_VEXPRESS_CA15_UART
+	bool "Vexpress CA15 debug UART"
+	depends	on ARCH_VEXPRESS
+	help
+	  Say Y	here if	you want low-level debugging support on	the
+	  Cortex-A15 based Vexpress boards.
+
 endchoice
 
 config DEBUG_IMX_UART_PORT
-- 
2.26.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

  reply	other threads:[~2020-08-16 21:51 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-16 21:42 [PATCH 1/3] ARM: vexpress: set stdout path Lucas Stach
2020-08-16 21:42 ` Lucas Stach [this message]
2020-08-17 10:31   ` [PATCH 2/3] ARM: vexpress: allow to select debug UART address Sascha Hauer
2020-08-16 21:42 ` [PATCH 3/3] ARM: vexpress: enable KALLSYMS in defconfig Lucas Stach
2020-08-17  4:54 ` [PATCH 1/3] ARM: vexpress: set stdout path Sascha Hauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200816214242.137168-2-dev@lynxeye.de \
    --to=dev@lynxeye.de \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox