From: john stultz <johnstul@us.ibm.com>
To: Dominik Brodowski <linux@dominikbrodowski.de>
Cc: lkml <linux-kernel@vger.kernel.org>,
george anzinger <george@mvista.com>, greg kh <greg@kroah.com>,
Chris McDermott <lcm@us.ibm.com>
Subject: Re: Too much error in __const_udelay() ?
Date: Mon, 07 Jun 2004 13:27:25 -0700 [thread overview]
Message-ID: <1086640044.2234.176.camel@cog.beaverton.ibm.com> (raw)
In-Reply-To: <1086635568.2234.171.camel@cog.beaverton.ibm.com>
On Mon, 2004-06-07 at 12:12, john stultz wrote:
> I'm also spinning up a patch w/ these changes to test, let me know how
> your testing went and I'll do the same.
The following patch of your suggestions resolves the USB problem for me.
I'd be interested if anyone else could test this to insure it doesn't
open up any other issues.
thanks
-john
===== arch/i386/lib/delay.c 1.5 vs edited =====
--- 1.5/arch/i386/lib/delay.c Wed Jul 2 21:21:32 2003
+++ edited/arch/i386/lib/delay.c Mon Jun 7 12:17:26 2004
@@ -33,13 +33,13 @@
int d0;
__asm__("mull %0"
:"=d" (xloops), "=&a" (d0)
- :"1" (xloops),"0" (current_cpu_data.loops_per_jiffy));
- __delay(xloops * HZ);
+ :"1" (xloops),"0" (HZ*current_cpu_data.loops_per_jiffy));
+ __delay(xloops?xloops:1);
}
void __udelay(unsigned long usecs)
{
- __const_udelay(usecs * 0x000010c6); /* 2**32 / 1000000 */
+ __const_udelay(usecs * 0x000010c7); /* 2**32 / 1000000 */
}
void __ndelay(unsigned long nsecs)
===== include/asm-i386/delay.h 1.2 vs edited =====
--- 1.2/include/asm-i386/delay.h Tue Feb 18 06:40:31 2003
+++ edited/include/asm-i386/delay.h Mon Jun 7 12:16:42 2004
@@ -16,7 +16,7 @@
extern void __delay(unsigned long loops);
#define udelay(n) (__builtin_constant_p(n) ? \
- ((n) > 20000 ? __bad_udelay() : __const_udelay((n) * 0x10c6ul)) : \
+ ((n) > 20000 ? __bad_udelay() : __const_udelay((n) * 0x10c7ul)) : \
__udelay(n))
#define ndelay(n) (__builtin_constant_p(n) ? \
next prev parent reply other threads:[~2004-06-07 20:27 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-06-05 7:12 john stultz
2004-06-05 15:23 ` Dominik Brodowski
2004-06-06 19:46 ` Pavel Machek
2004-06-07 19:12 ` john stultz
2004-06-07 20:27 ` john stultz [this message]
2004-06-07 21:20 ` [PATCH 1/3] mull'ify multiplication with HZ in __const_udelay() [Was: Re: Too much error in __const_udelay() ?] Dominik Brodowski
2004-06-07 22:00 ` john stultz
2004-06-15 6:11 ` Dominik Brodowski
2004-06-07 21:22 ` [PATCH 2/3] round up in __udelay() " Dominik Brodowski
2004-06-07 21:23 ` [PATCH 3/3] fix for small xloops " Dominik Brodowski
2004-06-09 10:03 ` Pavel Machek
2004-06-07 21:23 ` Too much error in __const_udelay() ? Dominik Brodowski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1086640044.2234.176.camel@cog.beaverton.ibm.com \
--to=johnstul@us.ibm.com \
--cc=george@mvista.com \
--cc=greg@kroah.com \
--cc=lcm@us.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@dominikbrodowski.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®