summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-w90x900/include
diff options
context:
space:
mode:
authorwanzongshun <mcuos.com@gmail.com>2009-12-18 18:00:37 +0100
committerRussell King <rmk+kernel@arm.linux.org.uk>2009-12-22 16:32:32 +0100
commit040f04598c6f494796815a4fc203379ff9fb847e (patch)
tree8136270a5174eee4a2e47be8cf62bd743b6a5b51 /arch/arm/mach-w90x900/include
parentARM: 5854/1: fix compiling error for NUC900 (diff)
downloadlinux-040f04598c6f494796815a4fc203379ff9fb847e.tar.xz
linux-040f04598c6f494796815a4fc203379ff9fb847e.zip
ARM: 5855/1: putc support for nuc900
putc support for nuc900 Signed-off-by: lijie <eltshanli@gmail.com> Signed-off-by: Wan ZongShun <mcuos.com@gmail.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-w90x900/include')
-rw-r--r--arch/arm/mach-w90x900/include/mach/uncompress.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/arch/arm/mach-w90x900/include/mach/uncompress.h b/arch/arm/mach-w90x900/include/mach/uncompress.h
index 050d9fe5ae1b..56f1a74d7016 100644
--- a/arch/arm/mach-w90x900/include/mach/uncompress.h
+++ b/arch/arm/mach-w90x900/include/mach/uncompress.h
@@ -22,11 +22,21 @@
#include <mach/regs-serial.h>
#include <mach/map.h>
+#include <linux/serial_reg.h>
#define arch_decomp_wdog()
+#define TX_DONE (UART_LSR_TEMT | UART_LSR_THRE)
+static volatile u32 * uart_base = (u32 *)UART0_PA;
+
static void putc(int ch)
{
+ /* Check THRE and TEMT bits before we transmit the character.
+ */
+ while ((uart_base[UART_LSR] & TX_DONE) != TX_DONE)
+ barrier();
+
+ *uart_base = ch;
}
static inline void flush(void)