]> git.karo-electronics.de Git - karo-tx-linux.git/commit
[PATCH] Fix sparc32 udelay() rounding errors.
authorMark Fortescue <mark@mtfhpc.demon.co.uk>
Wed, 25 Jul 2007 04:45:44 +0000 (21:45 -0700)
committerWilly Tarreau <w@1wt.eu>
Sat, 25 Aug 2007 15:24:01 +0000 (17:24 +0200)
commit924208714f0952c9db54121b99b885760917ef57
tree86f1fbf2ad16619ab96902a3b0471526ba61c09a
parent461da1de5ee6ee7f4848840d296c28a60c8b50e7
[PATCH] Fix sparc32 udelay() rounding errors.

[SPARC32]: Fix rounding errors in ndelay/udelay implementation.

__ndelay and __udelay have not been delayung >= specified time.
The problem with __ndelay has been tacked down to the rounding of the
multiplier constant. By changing this, delays > app 18us are correctly
calculated.
The problem with __udelay has also been tracked down to rounding issues.
Changing the multiplier constant (to match that used in sparc64) corrects
for large delays and adding in a rounding constant corrects for trunctaion
errors in the claculations.
Many short delays will return without looping. This is not an error as there
is the fixed delay of doing all the maths to calculate the loop count.

Signed-off-by: Mark Fortescue <mark@mtfhpc.demon.co.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Willy Tarreau <w@1wt.eu>
arch/sparc/kernel/entry.S