aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/serial/s3c2410.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/serial/s3c2410.c')
-rw-r--r--drivers/serial/s3c2410.c26
1 files changed, 10 insertions, 16 deletions
diff --git a/drivers/serial/s3c2410.c b/drivers/serial/s3c2410.c
index 7410e093a6b9..e4d701239702 100644
--- a/drivers/serial/s3c2410.c
+++ b/drivers/serial/s3c2410.c
@@ -1584,25 +1584,19 @@ s3c24xx_serial_console_txrdy(struct uart_port *port, unsigned int ufcon)
1584} 1584}
1585 1585
1586static void 1586static void
1587s3c24xx_serial_console_write(struct console *co, const char *s, 1587s3c24xx_serial_console_putchar(struct uart_port *port, int ch)
1588 unsigned int count)
1589{ 1588{
1590 int i;
1591 unsigned int ufcon = rd_regl(cons_uart, S3C2410_UFCON); 1589 unsigned int ufcon = rd_regl(cons_uart, S3C2410_UFCON);
1590 while (!s3c24xx_serial_console_txrdy(port, ufcon))
1591 barrier();
1592 wr_regb(cons_uart, S3C2410_UTXH, ch);
1593}
1592 1594
1593 for (i = 0; i < count; i++) { 1595static void
1594 while (!s3c24xx_serial_console_txrdy(cons_uart, ufcon)) 1596s3c24xx_serial_console_write(struct console *co, const char *s,
1595 barrier(); 1597 unsigned int count)
1596 1598{
1597 wr_regb(cons_uart, S3C2410_UTXH, s[i]); 1599 uart_console_write(cons_uart, s, count, s3c24xx_serial_console_putchar);
1598
1599 if (s[i] == '\n') {
1600 while (!s3c24xx_serial_console_txrdy(cons_uart, ufcon))
1601 barrier();
1602
1603 wr_regb(cons_uart, S3C2410_UTXH, '\r');
1604 }
1605 }
1606} 1600}
1607 1601
1608static void __init 1602static void __init