The patch titled mmc: avoid some resets without card has been added to the -mm tree. Its filename is mmc-avoid-some-resets-without-card.patch See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find out what to do about this ------------------------------------------------------ Subject: mmc: avoid some resets without card From: Pierre Ossman <drzeus@xxxxxxxxx> Some Ricoh controllers only respect a full reset when there is no card in the slot. As we wait for the reset to complete, we must avoid even requesting those resets on the buggy controllers. Signed-off-by: Pierre Ossman <drzeus@xxxxxxxxx> Cc: Russell King <rmk@xxxxxxxxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxx> --- drivers/mmc/sdhci.c | 17 +++++++++++++---- 1 files changed, 13 insertions(+), 4 deletions(-) diff -puN drivers/mmc/sdhci.c~mmc-avoid-some-resets-without-card drivers/mmc/sdhci.c --- a/drivers/mmc/sdhci.c~mmc-avoid-some-resets-without-card +++ a/drivers/mmc/sdhci.c @@ -35,6 +35,8 @@ static unsigned int debug_quirks = 0; #define SDHCI_QUIRK_CLOCK_BEFORE_RESET (1<<0) #define SDHCI_QUIRK_FORCE_DMA (1<<1) +/* Controller doesn't like some resets when there is no card inserted. */ +#define SDHCI_QUIRK_NO_CARD_NO_RESET (1<<2) static const struct pci_device_id pci_ids[] __devinitdata = { { @@ -51,7 +53,8 @@ static const struct pci_device_id pci_id .device = PCI_DEVICE_ID_RICOH_R5C822, .subvendor = PCI_ANY_ID, .subdevice = PCI_ANY_ID, - .driver_data = SDHCI_QUIRK_FORCE_DMA, + .driver_data = SDHCI_QUIRK_FORCE_DMA | + SDHCI_QUIRK_NO_CARD_NO_RESET, }, { @@ -125,6 +128,12 @@ static void sdhci_reset(struct sdhci_hos { unsigned long timeout; + if (host->chip->quirks & SDHCI_QUIRK_NO_CARD_NO_RESET) { + if (!(readl(host->ioaddr + SDHCI_PRESENT_STATE) & + SDHCI_CARD_PRESENT)) + return; + } + writeb(mask, host->ioaddr + SDHCI_SOFTWARE_RESET); if (mask & SDHCI_RESET_ALL) @@ -1174,6 +1183,9 @@ static int __devinit sdhci_probe_slot(st host = mmc_priv(mmc); host->mmc = mmc; + host->chip = chip; + chip->hosts[slot] = host; + host->bar = first_bar + slot; host->addr = pci_resource_start(pdev, host->bar); @@ -1330,9 +1342,6 @@ static int __devinit sdhci_probe_slot(st sdhci_dumpregs(host); #endif - host->chip = chip; - chip->hosts[slot] = host; - mmiowb(); mmc_add_host(mmc); _ Patches currently in -mm which might be from drzeus@xxxxxxxxx are origin.patch acpi-fix-section-for-cpu-init-functions.patch mmc-driver-for-ti-flashmedia-card-reader-source.patch mmc-driver-for-ti-flashmedia-card-reader-kconfig-makefile.patch mmc-fix-mmio-vs-memory-races-in-sdhci.patch mmc-avoid-some-resets-without-card.patch mmc-use-own-work-queue.patch mmc-properly-use-the-new-multi-block-write-error-handling.patch mmc-multi-sector-write-transfers.patch - To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html