From: Yinghai Lu <yinghai@kernel.org>
To: Thomas Gleixner <tglx@linutronix.de>
Cc: Greg KH <greg@kroah.com>,
Benjamin Herrenschmidt <benh@kernel.crashing.org>,
Andrew Morton <akpm@linux-foundation.org>,
Ingo Molnar <mingo@elte.hu>, "H. Peter Anvin" <hpa@zytor.com>,
Jesse Barnes <jbarnes@virtuousgeek.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
Christoph Lameter <cl@linux.com>, Tejun Heo <tj@kernel.org>
Subject: Re: [RFC PATCH] x86: Add safe_udelay() and safe_msleep()
Date: Fri, 14 Jan 2011 14:42:24 -0800 [thread overview]
Message-ID: <4D30D150.9030900@kernel.org> (raw)
In-Reply-To: <alpine.LFD.2.00.1101140014590.2678@localhost6.localdomain6>
On 01/13/2011 03:31 PM, Thomas Gleixner wrote:
> On Thu, 13 Jan 2011, Yinghai Lu wrote:
>
>>>
>>> What the hell is the root problem ?
>>
>> for patch
>>
>> x86: usb handoff in early_quirk
>>
>> some systems keep getting
>> APIC calibration not consistent with PM-Timer: 139ms instead of 100ms
>> APIC delta adjusted to PM-Timer: 831249 (1163736)
>>
>> USB legacy SMI handler is not disabled at that time.
>>
>> According to Thomas:
>> | http://lkml.indiana.edu/hypermail/linux/kernel/0703.2/0420.html
>> |
>> | The wrong calibration values are probably caused by SMM code trying to
>> | emulate a PS/2 keyboard from a (maybe connected or not) USB keyboard.
>> | This prohibits the accurate delivery of PIT interrupts, which are used
>> | to calibrate the local APIC timer. Unfortunately we have no way to
>> | disable this BIOS misfeature in the early boot process.
>>
>> Try to disable USB legacy support early with this patch.
>> So later APIC Timer calibration don't get messed up by USB legacy support SMI handler.
>> After this patch, that warning never show up for 100 reboot tests.
>>
>> reuse code from drivers/usb/host/pci-quirks.c
>>
>>
>> but pci-quirks.c is using udelay and msleep ...
>>
>> And BenH does't want
>> 1. if (early)...
>> 2. include .c
>> 3. new API new about safe_udelay/safe_msleep...
>>
>> just want to keep the old udelay/mdelay.
>
> NAK. That's the total wrong thing to do.
>
> Do we have any indication that we miscalibrate? If no, then were is
> the point of this ? If yes, then I it's way easier to fix that than
> doing all this ugly churn.
>
> We deal with that SMI crap in the TSC calibration as well and I'd
> rather see a combined TSC/APIC calibration than all this fugliness.
maybe disabling USB legacy support early patches could help this one?
http://ubuntuforums.org/archive/index.php/t-1289119.html
| Recently changed motherboard and cpu to
| gigabyte ga-ma790xt-ud4p and amd phenom II x4 965.
|
| Sometimes (and I mean sometimes) ubuntu 9.04 does not recognize
| all cpu cores, but 1 (sometimes :) even 2 or 3).
| I have tried Karmic(9.10), and at first it recognized all cores, but now it
| is back to normal (random not recognizing).
...
| sgb October 16th, 2009, 01:03 PM
| Thanks everyone,
| I have resolved the issue.
| Unbelievable as it is: four port USB hub was responsible
| for this random behavior. As soon as it is removed,
| everything is working as it should.
| I am amazed...
| But it's working now. :)
| If anyone has any theory how windows bypassed it,
| and why linux *sometimes* did, and sometimes did not,
| I would really like to hear... :confused:
| Thanks again for Your effort.
next prev parent reply other threads:[~2011-01-14 22:43 UTC|newest]
Thread overview: 57+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-01-09 19:58 [PATCH 0/3] x86, usb, pci: Disable usb legacy support early Yinghai Lu
2011-01-10 8:43 ` [PATCH -v2 0/4] " Yinghai Lu
2011-01-11 0:49 ` [PATCH -v3 " Yinghai Lu
2011-01-11 0:55 ` [PATCH -v3 1/4] pci, usb: Make usb handoff func all take base remapping Yinghai Lu
2011-01-11 1:07 ` Greg KH
2011-01-11 1:20 ` Yinghai Lu
2011-01-11 3:37 ` Greg KH
2011-01-11 5:21 ` Benjamin Herrenschmidt
2011-01-11 6:34 ` Yinghai Lu
2011-01-11 7:37 ` Benjamin Herrenschmidt
2011-01-11 9:21 ` Yinghai Lu
2011-01-11 13:56 ` Greg KH
2011-01-11 17:39 ` Konrad Rzeszutek Wilk
2011-01-12 1:06 ` [RFC PATCH] x86: Add safe_udelay() and safe_msleep() Yinghai Lu
2011-01-12 2:32 ` Benjamin Herrenschmidt
2011-01-12 5:07 ` Greg KH
2011-01-13 22:21 ` Yinghai Lu
2011-01-13 22:44 ` Greg KH
2011-01-13 22:52 ` Thomas Gleixner
2011-01-13 23:02 ` Greg KH
2011-01-13 23:04 ` Yinghai Lu
2011-01-13 23:31 ` Thomas Gleixner
2011-01-14 22:42 ` Yinghai Lu [this message]
2011-01-13 23:48 ` Greg KH
2011-01-14 0:31 ` Yinghai Lu
2011-01-14 0:40 ` Benjamin Herrenschmidt
2011-01-14 1:00 ` Yinghai Lu
2011-01-14 14:46 ` Christoph Lameter
2011-01-14 0:44 ` Greg KH
2011-01-14 1:12 ` Yinghai Lu
2011-01-14 14:50 ` Christoph Lameter
2011-01-14 21:22 ` [PATCH] x86: set percpu cpu0 lpj to default Yinghai Lu
2011-01-14 21:28 ` Christoph Lameter
2011-01-15 13:09 ` Tejun Heo
2011-01-16 2:32 ` Yinghai Lu
2011-01-14 22:16 ` Greg KH
2011-01-14 22:29 ` Yinghai Lu
2011-01-11 5:18 ` [PATCH -v3 1/4] pci, usb: Make usb handoff func all take base remapping Benjamin Herrenschmidt
2011-01-11 0:55 ` [PATCH 2/4] x86: early_quirk check all dev/func in domain 0 Yinghai Lu
2011-01-11 1:09 ` Greg KH
2011-01-11 1:46 ` Yinghai Lu
2011-01-11 3:38 ` Greg KH
2011-01-11 3:39 ` Greg KH
2011-01-11 0:55 ` [PATCH 3/4] x86, pci: add dummy pci device for early stage Yinghai Lu
2011-01-11 0:55 ` [PATCH -v3 4/4] x86: usb handoff in early_quirk Yinghai Lu
2011-01-11 1:08 ` Greg KH
2011-01-11 1:41 ` Yinghai Lu
2011-01-11 1:07 ` [PATCH -v3 0/4] x86, usb, pci: Disable usb legacy support early Greg KH
2011-01-11 1:25 ` Yinghai Lu
2011-01-11 3:35 ` Greg KH
[not found] ` <4D2AC584.6010004@kernel.org>
2011-01-10 8:43 ` [PATCH -v2 1/4] pci, usb: Seperate usb handoff func to another file Yinghai Lu
2011-01-10 8:44 ` [PATCH 2/4] x86: early_quirk check all dev/func in domain 0 Yinghai Lu
2011-01-10 8:44 ` [PATCH 3/4] x86, pci: add dummy pci device for early stage Yinghai Lu
2011-01-10 8:44 ` [PATCH v2 4/4] x86: usb handoff in early_quirk Yinghai Lu
2011-01-10 15:57 ` [PATCH 0/3] x86, usb, pci: Disable usb legacy support early Greg KH
2011-01-10 18:27 ` Jesse Barnes
2011-01-10 20:10 ` Yinghai Lu
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=4D30D150.9030900@kernel.org \
--to=yinghai@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=benh@kernel.crashing.org \
--cc=cl@linux.com \
--cc=greg@kroah.com \
--cc=hpa@zytor.com \
--cc=jbarnes@virtuousgeek.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=tglx@linutronix.de \
--cc=tj@kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).