diff options
author | Vincent Yang <vincent.yang.fujitsu@gmail.com> | 2015-01-20 16:05:15 +0800 |
---|---|---|
committer | Ulf Hansson <ulf.hansson@linaro.org> | 2015-01-20 09:29:16 +0100 |
commit | 9d967a61b4fc77b12f4b038a9345b5cda5bb2a7a (patch) | |
tree | 01b75ef511c109117a5c1139fd410c6b847a813f /drivers/mmc/host/sdhci.c | |
parent | 29d0d161c4ff252c3f9376d5ab05458a494a01ba (diff) | |
download | linux-9d967a61b4fc77b12f4b038a9345b5cda5bb2a7a.tar.gz linux-9d967a61b4fc77b12f4b038a9345b5cda5bb2a7a.tar.bz2 linux-9d967a61b4fc77b12f4b038a9345b5cda5bb2a7a.zip |
mmc: sdhci: add a voltage switch callback function
This patch adds a callback function to do
controller-specific actions when switching voltages.
It is a preparation and will be used by Fujitsu
SDHCI controller f_sdh30 driver.
Signed-off-by: Vincent Yang <Vincent.Yang@tw.fujitsu.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Diffstat (limited to 'drivers/mmc/host/sdhci.c')
-rw-r--r-- | drivers/mmc/host/sdhci.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c index 8b0c7d6ea04b..3e4fe967d7e5 100644 --- a/drivers/mmc/host/sdhci.c +++ b/drivers/mmc/host/sdhci.c @@ -1829,6 +1829,10 @@ static int sdhci_do_start_signal_voltage_switch(struct sdhci_host *host, ctrl |= SDHCI_CTRL_VDD_180; sdhci_writew(host, ctrl, SDHCI_HOST_CONTROL2); + /* Some controller need to do more when switching */ + if (host->ops->voltage_switch) + host->ops->voltage_switch(host); + /* 1.8V regulator output should be stable within 5 ms */ ctrl = sdhci_readw(host, SDHCI_HOST_CONTROL2); if (ctrl & SDHCI_CTRL_VDD_180) |