Hi All,
We are using two UARTs port in OMAP3430 board shown as following
UART 1 - not used
UART 2 - BT
UART 3 - console ("console=ttyS2,115200n8" in 'bootargs' of bootloader)
Because we are not using UART port 1, I configured our board file as following
735 static struct omap_uart_config omap3_boardname_uart_config __initdata = {
736 .enabled_uarts = ((1 << 1) | (1 << 2)),
737 };
However, I couldn't see any console message.
If I configured like
735 static struct omap_uart_config omap3_boardname_uart_config __initdata = {
736 .enabled_uarts = ((1 << 0) (1 << 1) | (1 << 2)),
737 };
I could see console messages. But I think this is not the real solution.
Is it correct to use ttyS2, if I use UART3 as console UART?
Anyway, I kept track of this problem and I'm sending the patch.
Please let me know your opinion about this patch.
---
>From 88fc1f0872fd2c6ac42501027e5bf69156cce37f Mon Sep 17 00:00:00 2001
From: Kim Kyuwon <[email protected]>
Date: Thu, 14 May 2009 17:05:35 +0900
Subject: [PATCH] OMAP: UART: don't initialize membase and mapbase when
its port is not enabled
If membase and mapbase are zero, its uart port which is registered to
serial8250(i.e serial8250_port[i]) is overridden, because the
serial8250_find_match_or_unsed() function consider this port as a
unused entry. This make the serial2850_console_setup function use
incorrect uart port, because co->index is used as the index of
serial8250_port. This patch prevent using wrong index of uart.
Signed-off-by: Kim Kyuwon <[email protected]>
---
arch/arm/mach-omap2/serial.c | 5 +----
1 files changed, 1 insertions(+), 4 deletions(-)
diff --git a/arch/arm/mach-omap2/serial.c b/arch/arm/mach-omap2/serial.c
index 4dcf39c..01c2da7 100644
--- a/arch/arm/mach-omap2/serial.c
+++ b/arch/arm/mach-omap2/serial.c
@@ -118,11 +118,8 @@ void __init omap_serial_init(void)
for (i = 0; i < OMAP_MAX_NR_PORTS; i++) {
struct plat_serial8250_port *p = serial_platform_data + i;
- if (!(info->enabled_uarts & (1 << i))) {
- p->membase = NULL;
- p->mapbase = 0;
+ if (!(info->enabled_uarts & (1 << i)))
continue;
- }
sprintf(name, "uart%d_ick", i+1);
uart_ick[i] = clk_get(NULL, name);
--
1.5.2.5
--
Kyuwon (규원)
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html