summaryrefslogtreecommitdiff
path: root/lib_nios/time.c
diff options
context:
space:
mode:
authorwdenk <wdenk>2004-02-23 23:54:43 +0000
committerwdenk <wdenk>2004-02-23 23:54:43 +0000
commit028ab6b598b628326116acd88e0f35aa9f526d12 (patch)
tree0d54315bd92d713a405004b6e36fca8d2b7c53e3 /lib_nios/time.c
parent63e73c9a8ed5b32d9c4067ffaad953e9a8fe8f0a (diff)
* Patch by Peter Ryser, 20 Feb 2004:
Add support for the Xilinx ML300 platform * Patch by Stephan Linz, 17 Feb 2004: Fix watchdog support for NIOS * Patch by Josh Fryman, 16 Feb 2004: Fix byte-swapping for cfi_flash.c for different bus widths * Patch by Jon Diekema, 14 Jeb 2004: Remove duplicate "FPGA Support" notes from the README file
Diffstat (limited to 'lib_nios/time.c')
-rw-r--r--lib_nios/time.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib_nios/time.c b/lib_nios/time.c
index 765b9c198..25a233ea7 100644
--- a/lib_nios/time.c
+++ b/lib_nios/time.c
@@ -22,6 +22,7 @@
*/
#include <common.h>
+#include <watchdog.h>
extern void dly_clks( unsigned long ticks );
@@ -33,5 +34,6 @@ void udelay(unsigned long usec)
* cpu clocks.
*/
unsigned long cnt = (CONFIG_SYS_CLK_FREQ/1000000) * usec;
+ WATCHDOG_RESET (); /* trigger watchdog if needed */
dly_clks (cnt);
}