summaryrefslogtreecommitdiffstats
path: root/drivers/serial/mux.c
diff options
context:
space:
mode:
authorRyan Bradetich <rbrad@parisc-linux.org>2006-11-03 05:52:41 +0000
committerKyle McMartin <kyle@ubuntu.com>2006-12-08 00:34:08 -0500
commit3de7b6482b4e9a34f91604ee0fb7a3ace250f3bb (patch)
tree40ee06f7dc65951e9509ac4486f3a5a634cba28b /drivers/serial/mux.c
parent4bd5d82779466a2969c631ce283bef926680c9f5 (diff)
downloadlinux-3de7b6482b4e9a34f91604ee0fb7a3ace250f3bb.tar.bz2
[PARISC] [MUX] Mux driver updates
This patch changes the Mux console to use the Mux hardware instead of the PDC Software console. Signed-off-by: Ryan Bradetich <rbrad@parisc-linux.org> Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
Diffstat (limited to 'drivers/serial/mux.c')
-rw-r--r--drivers/serial/mux.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/drivers/serial/mux.c b/drivers/serial/mux.c
index ec57a616788b..6408b9b1561a 100644
--- a/drivers/serial/mux.c
+++ b/drivers/serial/mux.c
@@ -376,8 +376,17 @@ static void mux_poll(unsigned long unused)
#ifdef CONFIG_SERIAL_MUX_CONSOLE
static void mux_console_write(struct console *co, const char *s, unsigned count)
{
- while(count--)
- pdc_iodc_putc(*s++);
+ /* Wait until the FIFO drains. */
+ while(UART_GET_FIFO_CNT(&mux_ports[0].port))
+ udelay(1);
+
+ while(count--) {
+ if(*s == '\n') {
+ UART_PUT_CHAR(&mux_ports[0].port, '\r');
+ }
+ UART_PUT_CHAR(&mux_ports[0].port, *s++);
+ }
+
}
static int mux_console_setup(struct console *co, char *options)