summaryrefslogtreecommitdiff
path: root/lib_nios/time.c
diff options
context:
space:
mode:
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 765b9c1989a..25a233ea785 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);
}