]> bbs.cooldavid.org Git - net-next-2.6.git/commitdiff
mmc: sdhci: highspeed: check for mmc as well as sd cards
authorPhilip Rakity <prakity@marvell.com>
Wed, 6 Oct 2010 18:57:23 +0000 (11:57 -0700)
committerChris Ball <cjb@laptop.org>
Sat, 23 Oct 2010 13:11:19 +0000 (21:11 +0800)
The SD and MMC code set highspeed using different constants.
Change the sd driver to recognize this and switch to high speed.
Validated code when testing eMMC dual data rate.

Signed-off-by: Philip Rakity <prakity@marvell.com>
[cjb: changelog + indentation fixes]
Signed-off-by: Chris Ball <cjb@laptop.org>
drivers/mmc/host/sdhci.c

index d3f924bcfffd178bee79529d4e0bb51b6ae2a891..23358d339a6831ddcce9fde228703c6b77c92b93 100644 (file)
@@ -1194,8 +1194,9 @@ static void sdhci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
        else
                ctrl &= ~SDHCI_CTRL_4BITBUS;
 
-       if (ios->timing == MMC_TIMING_SD_HS &&
-           !(host->quirks & SDHCI_QUIRK_NO_HISPD_BIT))
+       if ((ios->timing == MMC_TIMING_SD_HS ||
+            ios->timing == MMC_TIMING_MMC_HS)
+           && !(host->quirks & SDHCI_QUIRK_NO_HISPD_BIT))
                ctrl |= SDHCI_CTRL_HISPD;
        else
                ctrl &= ~SDHCI_CTRL_HISPD;