]> err.no Git - linux-2.6/blobdiff - drivers/serial/vr41xx_siu.c
[PATCH] USB: unusual_devs entry for Nokia N91
[linux-2.6] / drivers / serial / vr41xx_siu.c
index bd6294132c18ff81f29d09bdaf48f86a6b14ecb1..e93d0edc2e0890b79accfcb488abbe7980d8620e 100644 (file)
@@ -19,7 +19,6 @@
  *  along with this program; if not, write to the Free Software
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  */
-#include <linux/config.h>
 
 #if defined(CONFIG_SERIAL_VR41XX_CONSOLE) && defined(CONFIG_MAGIC_SYSRQ)
 #define SUPPORT_SYSRQ
@@ -821,25 +820,23 @@ static void wait_for_xmitr(struct uart_port *port)
        }
 }
 
+static void siu_console_putchar(struct uart_port *port, int ch)
+{
+       wait_for_xmitr(port);
+       siu_write(port, UART_TX, ch);
+}
+
 static void siu_console_write(struct console *con, const char *s, unsigned count)
 {
        struct uart_port *port;
        uint8_t ier;
-       unsigned i;
 
        port = &siu_uart_ports[con->index];
 
        ier = siu_read(port, UART_IER);
        siu_write(port, UART_IER, 0);
 
-       for (i = 0; i < count && *s != '\0'; i++, s++) {
-               wait_for_xmitr(port);
-               siu_write(port, UART_TX, *s);
-               if (*s == '\n') {
-                       wait_for_xmitr(port);
-                       siu_write(port, UART_TX, '\r');
-               }
-       }
+       uart_console_write(port, s, count, siu_console_putchar);
 
        wait_for_xmitr(port);
        siu_write(port, UART_IER, ier);
@@ -913,7 +910,6 @@ static struct uart_driver siu_uart_driver = {
        .owner          = THIS_MODULE,
        .driver_name    = "SIU",
        .dev_name       = "ttyVR",
-       .devfs_name     = "ttvr/",
        .major          = SIU_MAJOR,
        .minor          = SIU_MINOR_BASE,
        .cons           = SERIAL_VR41XX_CONSOLE,