Commit Graph

9 Commits

Author SHA1 Message Date
Pierre Ossman 6501ff604a sdio: give sdio irq thread a host specific name
There is one thread per host controller so make sure they all get
unique names.

Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
2008-10-12 11:04:30 +02:00
Pierre Ossman e633b7bcec sdio: make sleep on error interruptable
Make sure we can be woken from the forced sleep that is done on errors.
Removing a card often results in -ENOMEDIUM or -EILSEQ so we previously
locked up the removal process for a second.

We could completely exit on -ENOMEDIUM, but it might be a transient
glitch so treat it like any other error.

Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
2008-10-12 11:04:28 +02:00
Robert P. J. Day 6fee65cfde mmc: use shorter, equivalent set_current_state()
Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
2008-04-18 20:05:27 +02:00
Nicolas Pitre 599473cf15 sdio: make the IRQ thread more resilient in the presence of bad states
Currently we print a message about some bad states wrt function IRQ
handlers but return 0 from process_sdio_pending_irqs() nevertheless.
This can lead to an infinite loop as nothing might have cleared the
condition for the pending card interrupt from the host controller by
the time host->ops->enable_sdio_irq(host, 1) is called.

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
2007-10-06 17:51:45 +02:00
Nicolas Pitre 3e01e4bcdd sdio: fix IRQ diagnostic message
If func is actually null we won't get much from sdio_func_id(func).

Signed-off-by: Nicolas Pitre <nico@marvell.com>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
2007-10-06 17:48:57 +02:00
Pierre Ossman 6f4285d133 sdio: adaptive interrupt polling
The interrupt polling frequency is a compromise between power usage and
interrupt latency. Unfortunately, it affects throughput rather severely
for devices which require an interrupt for every chunk of data.

By making the polling frequency adaptive, we get better throughput with
those devices without sacficing too much power. Polling will quickly
increase when there is an actual interrupt, and slowly fall back to the
idle frequency when the interrupts stop coming.

Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
2007-09-27 10:48:29 +02:00
Pierre Ossman d84075c8ae mmc: replace BUG_ON with WARN_ON
Replace all cases of BUG_ON with WARN_ON where there is a chance
(with varying degrees of slim) that the kernel can continue without
incidence.

Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
2007-09-23 21:23:07 +02:00
Nicolas Pitre 17b759aff9 sdio: add interface for host side SDIO interrupt reporting
Signed-off-by: Nicolas Pitre <npitre@mvista.com>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
2007-09-23 21:13:08 +02:00
Nicolas Pitre d1496c39e5 sdio: core support for SDIO function interrupt
Signed-off-by: Nicolas Pitre <npitre@mvista.com>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
2007-09-23 21:01:33 +02:00