5#include <sys/kassert.h>
11#define COM1_BASE 0x3F8
12#define COM2_BASE 0x2F8
13#define COM3_BASE 0x3E8
14#define COM4_BASE 0x2E8
22#define UART_OFFSET_DATA 0
23#define UART_OFFSET_IER 1
24#define UART_OFFSET_IIR 2
25#define UART_OFFSET_LCR 3
26#define UART_LCR_DLAB 0x80
27#define UART_LCR_8N1 0x03
28#define UART_OFFSET_MCR 4
29#define UART_OFFSET_LSR 5
30#define UART_OFFSET_MSR 6
31#define UART_OFFSET_SR 7
33#define UART_OFFSET_DIVLO 0
34#define UART_OFFSET_DIVHI 1
static INLINE uint8_t inb(uint16_t port)
static INLINE void outb(uint16_t port, uint8_t data)
void IRQ_Register(int irq, struct IRQHandler *h)
int kprintf(const char *fmt,...)
#define UART_OFFSET_DIVLO
void Serial_LateInit(void)
static IRQHandler handler
void Serial_Putc(char ch)
void Serial_Puts(const char *str)
void Serial_Interrupt(void *arg)