summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorDavid Yu <davyu@nvidia.com>2014-01-27 19:54:33 +0900
committerHarry Hong <hhong@nvidia.com>2014-01-27 18:35:07 -0800
commitd158089ee8f7fe840fefc3d65b964503d4d0e4a8 (patch)
treec4488c5ea246dcbe301e10071b98c0659080f928 /drivers
parent477a5f171ca507b0f22d2d267397c3a246184402 (diff)
mmc: sdhci: tegra: fix power rail policy
Keep power rail on unless otherwise specified on shutdown. Bug 1445876 Change-Id: I5a0309226177c10ab52f25703c7133be63faa6b4 Signed-off-by: David Yu <davyu@nvidia.com> Reviewed-on: http://git-master/r/360385 Reviewed-by: Harry Hong <hhong@nvidia.com> Tested-by: Harry Hong <hhong@nvidia.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/mmc/host/sdhci-tegra.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/mmc/host/sdhci-tegra.c b/drivers/mmc/host/sdhci-tegra.c
index 573325e249f3..bcca95d2b9cd 100644
--- a/drivers/mmc/host/sdhci-tegra.c
+++ b/drivers/mmc/host/sdhci-tegra.c
@@ -350,6 +350,7 @@ struct sdhci_tegra {
struct tegra_tuning_data tuning_data[DFS_FREQ_COUNT];
bool is_parent_pllc;
struct tegra_freq_gov_data *gov_data;
+ bool power_off_rail;
};
static struct clk *pll_c;
@@ -3114,6 +3115,9 @@ static int __devinit sdhci_tegra_probe(struct platform_device *pdev)
/* Enable async suspend/resume to reduce LP0 latency */
device_enable_async_suspend(&pdev->dev);
+ if (plat->power_off_rail)
+ tegra_host->power_off_rail = true;
+
return 0;
err_add_host:
@@ -3197,6 +3201,9 @@ static void tegra_sdhci_shutdown(struct platform_device *pdev)
struct sdhci_tegra *tegra_host = pltfm_host->priv;
int err;
+ if (!tegra_host->power_off_rail)
+ return;
+
err = tegra_sdhci_configure_regulators(tegra_host,
CONFIG_REG_DIS, 0, 0);
if (err)