diff options
author | Russell King <rmk@dyn-67.arm.linux.org.uk> | 2006-03-28 10:24:33 +0100 |
---|---|---|
committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2006-03-28 10:24:33 +0100 |
commit | a081568d7016061ed848696984e3acf1ba0b3054 (patch) | |
tree | 5a6cd28d51e3c0b694499f4d0795b22a3d020eba /include/asm-arm/arch-s3c2410 | |
parent | 3747b36eeab93d8969e86987bbc1d44971229b26 (diff) |
[ARM] Fix decompressor serial IO to give CRLF not LFCR
As per the corresponding change to the serial drivers, arrange
for ARM decompressors to give CRLF. Move the common putstr code
into misc.c such that machines only need to supply "putc" and
"flush" functions.
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'include/asm-arm/arch-s3c2410')
-rw-r--r-- | include/asm-arm/arch-s3c2410/uncompress.h | 15 |
1 files changed, 4 insertions, 11 deletions
diff --git a/include/asm-arm/arch-s3c2410/uncompress.h b/include/asm-arm/arch-s3c2410/uncompress.h index 4367ec054b5..a6f6a0e44af 100644 --- a/include/asm-arm/arch-s3c2410/uncompress.h +++ b/include/asm-arm/arch-s3c2410/uncompress.h @@ -67,8 +67,7 @@ uart_rd(unsigned int reg) * waiting for tx to happen... */ -static void -putc(char ch) +static void putc(int ch) { int cpuid = S3C2410_GSTATUS1_2410; @@ -77,9 +76,6 @@ putc(char ch) cpuid &= S3C2410_GSTATUS1_IDMASK; #endif - if (ch == '\n') - putc('\r'); /* expand newline to \r\n */ - if (uart_rd(S3C2410_UFCON) & S3C2410_UFCON_FIFOMODE) { int level; @@ -101,19 +97,16 @@ putc(char ch) } else { /* not using fifos */ - while ((uart_rd(S3C2410_UTRSTAT) & S3C2410_UTRSTAT_TXE) != S3C2410_UTRSTAT_TXE); + while ((uart_rd(S3C2410_UTRSTAT) & S3C2410_UTRSTAT_TXE) != S3C2410_UTRSTAT_TXE) + barrier(); } /* write byte to transmission register */ uart_wr(S3C2410_UTXH, ch); } -static void -putstr(const char *ptr) +static inline void flush(void) { - for (; *ptr != '\0'; ptr++) { - putc(*ptr); - } } #define __raw_writel(d,ad) do { *((volatile unsigned int *)(ad)) = (d); } while(0) |