summaryrefslogtreecommitdiff
path: root/drivers/serial
diff options
context:
space:
mode:
authorWolfgang Denk <wd@denx.de>2011-06-23 15:37:33 +0200
committerWolfgang Denk <wd@denx.de>2011-06-23 15:37:33 +0200
commit9623c158f6a5150a21c25026bfba79e7ff7912f5 (patch)
tree2c4d4209a34baa810a6f3fb409e1f8e494f01b31 /drivers/serial
parent2ad6e27dcdbd694de8e3823d2b52b250b1a59219 (diff)
parent1ed63c549892bc3a4ce1a43f09a6a92a00054f3d (diff)
downloadu-boot-imx-9623c158f6a5150a21c25026bfba79e7ff7912f5.zip
u-boot-imx-9623c158f6a5150a21c25026bfba79e7ff7912f5.tar.gz
u-boot-imx-9623c158f6a5150a21c25026bfba79e7ff7912f5.tar.bz2
Merge branch 'master' of git://git.denx.de/u-boot-arm
* 'master' of git://git.denx.de/u-boot-arm: run arm_pci_init after relocation IXP42x PCI rewrite update/fix PDNB3 board update/fix IXDP425 / IXDPG425 boards add dvlhost (dLAN 200 AV Wireless G) board IXP NPE: add support for fixed-speed MII ports update/fix AcTux4 board update/fix AcTux3 board update/fix AcTux2 board update/fix AcTux1 board use -ffunction-sections / --gc-sections on IXP42x support CONFIG_SYS_LDSCRIPT on ARM fix "depend" target in npe directory Fix IXP code to work after relocation was added trigger hardware watchdog in IXP42x serial driver add support for IXP42x Rev. B1 and newer add XScale sub architecture (IXP/PXA) to maintainer list Conflicts: arch/arm/lib/board.c Signed-off-by: Wolfgang Denk <wd@denx.de>
Diffstat (limited to 'drivers/serial')
-rw-r--r--drivers/serial/serial_ixp.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/serial/serial_ixp.c b/drivers/serial/serial_ixp.c
index dd26af4..a9acd47 100644
--- a/drivers/serial/serial_ixp.c
+++ b/drivers/serial/serial_ixp.c
@@ -30,6 +30,7 @@
#include <common.h>
#include <asm/arch/ixp425.h>
+#include <watchdog.h>
/*
* 14.7456 MHz
@@ -85,7 +86,8 @@ int serial_init (void)
void serial_putc (const char c)
{
/* wait for room in the tx FIFO on UART */
- while ((LSR(CONFIG_SYS_IXP425_CONSOLE) & LSR_TEMT) == 0);
+ while ((LSR(CONFIG_SYS_IXP425_CONSOLE) & LSR_TEMT) == 0)
+ WATCHDOG_RESET(); /* Reset HW Watchdog, if needed */
THR(CONFIG_SYS_IXP425_CONSOLE) = c;
@@ -111,7 +113,8 @@ int serial_tstc (void)
*/
int serial_getc (void)
{
- while (!(LSR(CONFIG_SYS_IXP425_CONSOLE) & LSR_DR));
+ while (!(LSR(CONFIG_SYS_IXP425_CONSOLE) & LSR_DR))
+ WATCHDOG_RESET(); /* Reset HW Watchdog, if needed */
return (char) RBR(CONFIG_SYS_IXP425_CONSOLE) & 0xff;
}