Messages in this thread | | | Date | Sat, 1 Mar 2008 15:08:10 +0100 | From | Pierre Ossman <> | Subject | Re: Scheduler broken? sdhci issues with scheduling |
| |
On Sat, 1 Mar 2008 12:42:04 +0000 Simon Huggins <huggie@earth.li> wrote:
> > so neither precise, nor imprecise timings help?? > > I don't know. I don't really understand the patches I applied I'm > afraid; I'm just reporting the results. > > I've cc'd Pierre Ossman so he might have a look from the sdhci point of > view. > > Pierre, the thread starts here: > http://lkml.org/lkml/2008/2/29/118 >
I'm afraid I can't add that much...
Ingo, the basic problem is this:
The sdhci controllers are not supposed to signal "card insertion" before they have a stable connection with the card. But most (all?) hardware ignores this and signals immediately. This means we need a delay to handle bouncing connectors. This delay is supposed to be 500 ms, but on Simon's system it is in the order of tens of milliseconds.
The mechanism is not msleep(), nor mdelay(), but a delayed work queue. That's why I told Simon to talk to you as that seems like scheduler territory.
The call chain is:
1. sdhci_irq() 2. sdhci_tasklet_card() <- delay is calculated here 3. mmc_detect_change() 4. mmc_schedule_delayed_work() 5. queue_delayed_work()
msleep() and mdelay() are also affected, but this is the major symptom.
Rgds
-- -- Pierre Ossman
Linux kernel, MMC maintainer http://www.kernel.org PulseAudio, core developer http://pulseaudio.org rdesktop, core developer http://www.rdesktop.org
| |