1 #include <console/console.h>
3 #include <pc80/mc146818rtc.h>
7 #define TTYS0_BASE 0x3f8
11 #define TTYS0_BAUD 115200
14 #if ((115200%TTYS0_BAUD) != 0)
15 #error Bad ttys0 baud rate
18 #define TTYS0_DIV (115200/TTYS0_BAUD)
20 /* Line Control Settings */
22 /* Set 8bit, 1 stop bit, no parity */
26 #define UART_LCS TTYS0_LCS
30 static unsigned char div[8]={1,2,3,6,12,24,48,96};
32 unsigned int divisor=TTYS0_DIV;
34 if(get_option(&b_index,"baud_rate")==0) {
37 uart8250_init(TTYS0_BASE, divisor, TTYS0_LCS);
40 void ttyS0_tx_byte(unsigned char data)
42 uart8250_tx_byte(TTYS0_BASE, data);
45 static struct console_driver uart8250_console __console = {
47 .tx_byte = ttyS0_tx_byte,