2 * LZMA compressed kernel loader for Atheros AR7XXX/AR9XXX based boards
4 * Copyright (C) 2011 Gabor Juhos <juhosg@openwrt.org>
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License version 2 as published
8 * by the Free Software Foundation.
14 #define READREG(r) *(volatile unsigned int *)(r)
15 #define WRITEREG(r,v) *(volatile unsigned int *)(r) = v
17 #define UART_BASE 0xb8020000
22 #define UART_LSR_THRE 0x20
24 #define UART_READ(r) READREG(UART_BASE + 4 * (r))
25 #define UART_WRITE(r,v) WRITEREG(UART_BASE + 4 * (r), (v))
27 void board_putc(int ch
)
29 while (((UART_READ(UART_LSR
)) & UART_LSR_THRE
) == 0);
30 UART_WRITE(UART_TX
, ch
);
31 while (((UART_READ(UART_LSR
)) & UART_LSR_THRE
) == 0);
This page took 0.04645 seconds and 5 git commands to generate.