Path: blob/master/arch/arm/mach-kirkwood/include/mach/uncompress.h
10820 views
/*1* arch/arm/mach-kirkwood/include/mach/uncompress.h2*3* This file is licensed under the terms of the GNU General Public4* License version 2. This program is licensed "as is" without any5* warranty of any kind, whether express or implied.6*/78#include <linux/serial_reg.h>9#include <mach/kirkwood.h>1011#define SERIAL_BASE ((unsigned char *)UART0_PHYS_BASE)1213static void putc(const char c)14{15unsigned char *base = SERIAL_BASE;16int i;1718for (i = 0; i < 0x1000; i++) {19if (base[UART_LSR << 2] & UART_LSR_THRE)20break;21barrier();22}2324base[UART_TX << 2] = c;25}2627static void flush(void)28{29unsigned char *base = SERIAL_BASE;30unsigned char mask;31int i;3233mask = UART_LSR_TEMT | UART_LSR_THRE;3435for (i = 0; i < 0x1000; i++) {36if ((base[UART_LSR << 2] & mask) == mask)37break;38barrier();39}40}4142/*43* nothing to do44*/45#define arch_decomp_setup()46#define arch_decomp_wdog()474849