summaryrefslogtreecommitdiff
path: root/drivers/mmc/host/tmio_mmc_pio.c
diff options
context:
space:
mode:
authorChris Ball <cjb@laptop.org>2013-09-06 15:29:05 +0400
committerChris Ball <cjb@laptop.org>2013-09-06 15:29:05 +0400
commit9d731e7539713acc0ec7b67a5a91357c455d2334 (patch)
treef8979b956f68f77a9d995c816df59d3368a84bc2 /drivers/mmc/host/tmio_mmc_pio.c
parentb7d06c85a333b18b3fa03d2242cfec91f91fbea2 (diff)
downloadlinux-9d731e7539713acc0ec7b67a5a91357c455d2334.tar.xz
Revert "mmc: tmio-mmc: Remove .set_pwr() callback from platform data"
This reverts commit 3af9d15c719017feb63fa99f89ac6009a5a3d467, which causes a build failure: drivers/mfd/asic3.c:724:2: error: unknown field 'set_pwr' specified in initializer
Diffstat (limited to 'drivers/mmc/host/tmio_mmc_pio.c')
-rw-r--r--drivers/mmc/host/tmio_mmc_pio.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/mmc/host/tmio_mmc_pio.c b/drivers/mmc/host/tmio_mmc_pio.c
index 67a3bf1238cf..b3802256f954 100644
--- a/drivers/mmc/host/tmio_mmc_pio.c
+++ b/drivers/mmc/host/tmio_mmc_pio.c
@@ -777,6 +777,9 @@ static void tmio_mmc_power_on(struct tmio_mmc_host *host, unsigned short vdd)
/* .set_ios() is returning void, so, no chance to report an error */
+ if (host->set_pwr)
+ host->set_pwr(host->pdev, 1);
+
if (!IS_ERR(mmc->supply.vmmc)) {
ret = mmc_regulator_set_ocr(mmc, mmc->supply.vmmc, vdd);
/*
@@ -810,6 +813,9 @@ static void tmio_mmc_power_off(struct tmio_mmc_host *host)
if (!IS_ERR(mmc->supply.vmmc))
mmc_regulator_set_ocr(mmc, mmc->supply.vmmc, 0);
+
+ if (host->set_pwr)
+ host->set_pwr(host->pdev, 0);
}
/* Set MMC clock / power.
@@ -996,6 +1002,7 @@ int tmio_mmc_host_probe(struct tmio_mmc_host **host,
_host->pdev = pdev;
platform_set_drvdata(pdev, mmc);
+ _host->set_pwr = pdata->set_pwr;
_host->set_clk_div = pdata->set_clk_div;
/* SD control register space size is 0x200, 0x400 for bus_shift=1 */