tty: serial: 8250: export early_serial8250_setup function
authorEddie Huang <eddie.huang@mediatek.com>
Tue, 28 Apr 2015 13:40:32 +0000 (21:40 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 10 May 2015 17:00:05 +0000 (19:00 +0200)
8250-like uart driver may call early_serial8250_setup to
reuse 8250_early.c character output function.

Signed-off-by: Eddie Huang <eddie.huang@mediatek.com>
Tested-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/8250/8250_early.c
include/linux/serial_8250.h

index 6c0fd8b9d1c35b38b6019afd8a0fb293f0c117bc..771dda29a0f89e352c0180572bf5a59acb0f824f 100644 (file)
@@ -131,7 +131,7 @@ static void __init init_port(struct earlycon_device *device)
        serial8250_early_out(port, UART_LCR, c & ~UART_LCR_DLAB);
 }
 
-static int __init early_serial8250_setup(struct earlycon_device *device,
+int __init early_serial8250_setup(struct earlycon_device *device,
                                         const char *options)
 {
        if (!(device->port.membase || device->port.iobase))
index 78097e7a330a1984942796a4ecf9a156b93f5427..f0c68d88b6f462cb8d7b40bd6864b17941461e4a 100644 (file)
@@ -137,6 +137,8 @@ extern int early_serial_setup(struct uart_port *port);
 
 extern unsigned int serial8250_early_in(struct uart_port *port, int offset);
 extern void serial8250_early_out(struct uart_port *port, int offset, int value);
+extern int early_serial8250_setup(struct earlycon_device *device,
+                                        const char *options);
 extern void serial8250_do_set_termios(struct uart_port *port,
                struct ktermios *termios, struct ktermios *old);
 extern int serial8250_do_startup(struct uart_port *port);