]> err.no Git - linux-2.6/blobdiff - drivers/serial/sunsab.c
[PATCH] 8139cp: add ethtool eeprom support
[linux-2.6] / drivers / serial / sunsab.c
index 02f62da546b5f3bf57c541c66f83284a84e3d8a4..bfbe9dc90ccaa4fbc2316c2ed1acb20fcf7e0aa2 100644 (file)
@@ -861,8 +861,9 @@ static int num_channels;
 
 #ifdef CONFIG_SERIAL_SUNSAB_CONSOLE
 
-static __inline__ void sunsab_console_putchar(struct uart_sunsab_port *up, char c)
+static void sunsab_console_putchar(struct uart_port *port, int c)
 {
+       struct uart_sunsab_port *up = (struct uart_sunsab_port *)port;
        unsigned long flags;
 
        spin_lock_irqsave(&up->port.lock, flags);
@@ -876,13 +877,8 @@ static __inline__ void sunsab_console_putchar(struct uart_sunsab_port *up, char
 static void sunsab_console_write(struct console *con, const char *s, unsigned n)
 {
        struct uart_sunsab_port *up = &sunsab_ports[con->index];
-       int i;
 
-       for (i = 0; i < n; i++) {
-               if (*s == '\n')
-                       sunsab_console_putchar(up, '\r');
-               sunsab_console_putchar(up, *s++);
-       }
+       uart_console_write(&up->port, s, n, sunsab_console_putchar);
        sunsab_tec_wait(up);
 }
 
@@ -1142,6 +1138,8 @@ static int __init sunsab_init(void)
                return ret;
        }
 
+       sunsab_reg.tty_driver->name_base = sunsab_reg.minor - 64;
+
        sunsab_reg.cons = SUNSAB_CONSOLE();
 
        sunserial_current_minor += num_channels;