[MIPS] pnx8xxx: clocksource cleanups
[linux-2.6/linux-2.6-openrd.git] / arch / mips / qemu / q-console.c
blob81101ae5017a883d2c92eb3138768ea32736c8de
1 #include <linux/console.h>
2 #include <linux/init.h>
3 #include <linux/serial_reg.h>
4 #include <asm/io.h>
6 #define PORT(offset) (0x3f8 + (offset))
8 static inline unsigned int serial_in(int offset)
10 return inb(PORT(offset));
13 static inline void serial_out(int offset, int value)
15 outb(value, PORT(offset));
18 int prom_putchar(char c)
20 while ((serial_in(UART_LSR) & UART_LSR_THRE) == 0)
23 serial_out(UART_TX, c);
25 return 1;