Fedora kernel-2.6.17-1.2142_FC4 patched with stable patch-2.6.17.4-vs2.0.2-rc26.diff
[linux-2.6.git] / drivers / serial / 8250_early.c
index b7a5dd7..7e51119 100644 (file)
@@ -74,7 +74,7 @@ static void __init wait_for_xmitr(struct uart_port *port)
        }
 }
 
-static void __init putc(struct uart_port *port, unsigned char c)
+static void __init putc(struct uart_port *port, int c)
 {
        wait_for_xmitr(port);
        serial_out(port, UART_TX, c);
@@ -89,12 +89,7 @@ static void __init early_uart_write(struct console *console, const char *s, unsi
        ier = serial_in(port, UART_IER);
        serial_out(port, UART_IER, 0);
 
-       while (*s && count-- > 0) {
-               putc(port, *s);
-               if (*s == '\n')
-                       putc(port, '\r');
-               s++;
-       }
+       uart_console_write(port, s, count, putc);
 
        /* Wait for transmitter to become empty and restore the IER */
        wait_for_xmitr(port);
@@ -164,7 +159,7 @@ static int __init parse_options(struct early_uart_device *device, char *options)
 
        if ((options = strchr(options, ','))) {
                options++;
-               device->baud = simple_strtoul(options, 0, 0);
+               device->baud = simple_strtoul(options, NULL, 0);
                length = min(strcspn(options, " "), sizeof(device->options));
                strncpy(device->options, options, length);
        } else {