summaryrefslogtreecommitdiffstats
path: root/lib_mips/time.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib_mips/time.c')
-rw-r--r--lib_mips/time.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/lib_mips/time.c b/lib_mips/time.c
index 0cb733cb06..cd8dc721e2 100644
--- a/lib_mips/time.c
+++ b/lib_mips/time.c
@@ -75,9 +75,7 @@ void udelay (unsigned long usec)
ulong tmo;
ulong start = get_timer(0);
- tmo = usec * CFG_HZ / 1000;
- tmo /= 1000;
-
+ tmo = usec * (CFG_HZ / 1000000);
while ((ulong)((mips_count_get() - start)) < tmo)
/*NOP*/;
}
OpenPOWER on IntegriCloud