diff options
Diffstat (limited to 'arch/mn10300/lib')
-rw-r--r-- | arch/mn10300/lib/delay.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/mn10300/lib/delay.c b/arch/mn10300/lib/delay.c index fdf6f71..8e7ceb8 100644 --- a/arch/mn10300/lib/delay.c +++ b/arch/mn10300/lib/delay.c @@ -38,14 +38,14 @@ EXPORT_SYMBOL(__delay); */ void __udelay(unsigned long usecs) { - signed long ioclk, stop; + unsigned long start, stop, cnt; /* usecs * CLK / 1E6 */ stop = __muldiv64u(usecs, MN10300_TSCCLK, 1000000); - stop = TMTSCBC - stop; + start = TMTSCBC; do { - ioclk = TMTSCBC; - } while (stop < ioclk); + cnt = start - TMTSCBC; + } while (cnt < stop); } EXPORT_SYMBOL(__udelay); |