aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mmc
diff options
context:
space:
mode:
authorGuennadi Liakhovetski <g.liakhovetski@gmx.de>2011-03-09 08:38:58 -0500
committerChris Ball <cjb@laptop.org>2011-03-25 10:39:58 -0400
commita7edbe399b40fb82ccd11216fd88d24e428025c5 (patch)
tree2a46ebea94bf3cad5c9973fad6381a3450dec4a0 /drivers/mmc
parentd9b03421775d5cf8b4d5518a3e80b28cf3f999ce (diff)
mmc: tmio: fix power-mode interpretation
The power-mode sequence on MMC is MMC_POWER_OFF -> MMC_POWER_UP -> MMC_POWER_ON and not MMC_POWER_ON -> MMC_POWER_UP, as the driver currently is implying. Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de> Acked-by: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Chris Ball <cjb@laptop.org>
Diffstat (limited to 'drivers/mmc')
-rw-r--r--drivers/mmc/host/tmio_mmc_pio.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/mmc/host/tmio_mmc_pio.c b/drivers/mmc/host/tmio_mmc_pio.c
index e1aed255512..69772ab3ca2 100644
--- a/drivers/mmc/host/tmio_mmc_pio.c
+++ b/drivers/mmc/host/tmio_mmc_pio.c
@@ -746,20 +746,20 @@ static void tmio_mmc_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
746 if (ios->clock) 746 if (ios->clock)
747 tmio_mmc_set_clock(host, ios->clock); 747 tmio_mmc_set_clock(host, ios->clock);
748 748
749 /* Power sequence - OFF -> ON -> UP */ 749 /* Power sequence - OFF -> UP -> ON */
750 switch (ios->power_mode) { 750 switch (ios->power_mode) {
751 case MMC_POWER_OFF: /* power down SD bus */ 751 case MMC_POWER_OFF: /* power down SD bus */
752 if (host->set_pwr) 752 if (host->set_pwr)
753 host->set_pwr(host->pdev, 0); 753 host->set_pwr(host->pdev, 0);
754 tmio_mmc_clk_stop(host); 754 tmio_mmc_clk_stop(host);
755 break; 755 break;
756 case MMC_POWER_ON: /* power up SD bus */ 756 case MMC_POWER_ON: /* start bus clock */
757 tmio_mmc_clk_start(host);
758 break;
759 case MMC_POWER_UP: /* power up SD bus */
757 if (host->set_pwr) 760 if (host->set_pwr)
758 host->set_pwr(host->pdev, 1); 761 host->set_pwr(host->pdev, 1);
759 break; 762 break;
760 case MMC_POWER_UP: /* start bus clock */
761 tmio_mmc_clk_start(host);
762 break;
763 } 763 }
764 764
765 switch (ios->bus_width) { 765 switch (ios->bus_width) {