X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=include%2Fasm-arm%2Farch-aaec2000%2Funcompress.h;fp=include%2Fasm-arm%2Farch-aaec2000%2Funcompress.h;h=fff0c94b75c4c99c2de6976450766ca378eccf70;hb=64ba3f394c830ec48a1c31b53dcae312c56f1604;hp=300f4bf3bc74c0d973e48125a92d3adadc7d9694;hpb=be1e6109ac94a859551f8e1774eb9a8469fe055c;p=linux-2.6.git diff --git a/include/asm-arm/arch-aaec2000/uncompress.h b/include/asm-arm/arch-aaec2000/uncompress.h index 300f4bf3b..fff0c94b7 100644 --- a/include/asm-arm/arch-aaec2000/uncompress.h +++ b/include/asm-arm/arch-aaec2000/uncompress.h @@ -15,7 +15,7 @@ #define UART(x) (*(volatile unsigned long *)(serial_port + (x))) -static void putc(int c) +static void putstr( const char *s ) { unsigned long serial_port; do { @@ -28,16 +28,17 @@ static void putc(int c) return; } while (0); - /* wait for space in the UART's transmitter */ - while ((UART(UART_SR) & UART_SR_TxFF)) - barrier(); - - /* send the character out. */ - UART(UART_DR) = c; -} - -static inline void flush(void) -{ + for (; *s; s++) { + /* wait for space in the UART's transmitter */ + while ((UART(UART_SR) & UART_SR_TxFF)); + /* send the character out. */ + UART(UART_DR) = *s; + /* if a LF, also do CR... */ + if (*s == 10) { + while ((UART(UART_SR) & UART_SR_TxFF)); + UART(UART_DR) = 13; + } + } } #define arch_decomp_setup()