aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mmc
diff options
context:
space:
mode:
authorAndrei Warkentin <andreiw@motorola.com>2011-05-25 10:42:50 -0400
committerChris Ball <cjb@laptop.org>2011-05-25 16:52:26 -0400
commit4f3d3e9b50931a3ec70f324d53fb7437e2a39388 (patch)
tree26018537aaea287e7aa6377e2305a4222699b8d7 /drivers/mmc
parent8edf63710bd43e62d59bfe017df542fa0713bbb3 (diff)
mmc: sdhci: Auto-CMD23 fixes.
Fixes bugs in Auto-CMD23 feature enable decision. Auto-CMD23 should be enabled if host is >= v3, and SDMA is not in use. USE_ADMA | USE_SDMA | Auto-CMD23 ---------+----------+----------- 0 | 0 | 1 ---------+----------+----------- 0 | 1 | 0 ---------+----------+----------- 1 | 0 | 1 ---------+----------+----------- 1 | 1 | 1 Signed-off-by: Andrei Warkentin <andreiw@motorola.com> Signed-off-by: Chris Ball <cjb@laptop.org>
Diffstat (limited to 'drivers/mmc')
-rw-r--r--drivers/mmc/host/sdhci.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
index f845fd6a64ae..58d5436ff649 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
@@ -2494,9 +2494,9 @@ int sdhci_add_host(struct sdhci_host *host)
2494 host->flags |= SDHCI_AUTO_CMD12; 2494 host->flags |= SDHCI_AUTO_CMD12;
2495 2495
2496 /* Auto-CMD23 stuff only works in ADMA or PIO. */ 2496 /* Auto-CMD23 stuff only works in ADMA or PIO. */
2497 if ((host->version == SDHCI_SPEC_300) && 2497 if ((host->version >= SDHCI_SPEC_300) &&
2498 ((host->flags & SDHCI_USE_ADMA) || 2498 ((host->flags & SDHCI_USE_ADMA) ||
2499 !(host->flags & SDHCI_REQ_USE_DMA))) { 2499 !(host->flags & SDHCI_USE_SDMA))) {
2500 host->flags |= SDHCI_AUTO_CMD23; 2500 host->flags |= SDHCI_AUTO_CMD23;
2501 DBG("%s: Auto-CMD23 available\n", mmc_hostname(mmc)); 2501 DBG("%s: Auto-CMD23 available\n", mmc_hostname(mmc));
2502 } else { 2502 } else {