[PATCH 4/4] tty: Atmel serial: add linux,stdout-path support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@xxxxxxxxxxxx>
Cc: linux-serial@xxxxxxxxxxxxxxx
Cc: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
Cc: kernel@xxxxxxxxxxxxxx
Cc: Alan Cox <alan@xxxxxxxxxxxxxxx>
Cc: Grant Likely <grant.likely@xxxxxxxxxxxx>
Cc: Nicolas Ferre <nicolas.ferre@xxxxxxxxx>
---
 drivers/tty/serial/atmel_serial.c |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/tty/serial/atmel_serial.c b/drivers/tty/serial/atmel_serial.c
index 5608b6b..f62a3c3 100644
--- a/drivers/tty/serial/atmel_serial.c
+++ b/drivers/tty/serial/atmel_serial.c
@@ -1427,6 +1427,7 @@ static struct uart_ops atmel_pops = {
 static void __devinit atmel_of_init_port(struct atmel_uart_port *atmel_port,
 					 struct device_node *np)
 {
+	char *option = NULL;
 	u32 rs485_delay[2];
 
 	/* DMA/PDC usage specification */
@@ -1453,6 +1454,10 @@ static void __devinit atmel_of_init_port(struct atmel_uart_port *atmel_port,
 
 		if (of_get_property(np, "linux,rs485-enabled-at-boot-time", NULL))
 			rs485conf->flags |= SER_RS485_ENABLED;
+	} else if (of_device_is_stdout_path(np, &option)) {
+		pr_info("add preferred console %s%d option=%s\n",
+			ATMEL_DEVICENAME, atmel_port->uart.line, option);
+		add_preferred_console(ATMEL_DEVICENAME, atmel_port->uart.line, option);
 	}
 }
 
-- 
1.7.10.4

--
To unsubscribe from this list: send the line "unsubscribe linux-serial" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux PPP]     [Linux FS]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Linmodem]     [Device Mapper]     [Linux Kernel for ARM]

  Powered by Linux