mmc: host: tegra: Remove runtime DPD support in SD
rrajk [Thu, 9 May 2013 12:27:21 +0000 (17:27 +0530)]
Removed runtime DPD configuration support from SD driver.

Bug 1191332

Change-Id: I389ca46a302e30556d2823709a46816a582c26e4
Reviewed-on: http://git-master/r/227045
(cherry picked from commit 9ab1ae335d969eeffe5fc6c7f57e4b0a383ce20c)
Signed-off-by: rrajk <rrajk@nvidia.com>
Reviewed-on: http://git-master/r/231644
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Naveen Kumar Arepalli <naveenk@nvidia.com>
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>

drivers/mmc/host/sdhci-tegra.c

index 4c1345a..2b12b5c 100644 (file)
@@ -40,7 +40,6 @@
 
 #include <mach/gpio-tegra.h>
 #include <mach/sdhci.h>
-#include <mach/io_dpd.h>
 #include <mach/pinmux.h>
 #include <mach/clk.h>
 
@@ -1130,14 +1129,6 @@ static void tegra_sdhci_set_clock(struct sdhci_host *sdhci, unsigned int clock)
                mmc_hostname(sdhci->mmc), clock, tegra_host->clk_enabled);
 
        if (clock) {
-               /* bring out sd instance from io dpd mode */
-               if (tegra_host->dpd) {
-                       mutex_lock(&tegra_host->dpd->delay_lock);
-                       cancel_delayed_work_sync(&tegra_host->dpd->delay_dpd);
-                       tegra_io_dpd_disable(tegra_host->dpd);
-                       mutex_unlock(&tegra_host->dpd->delay_lock);
-               }
-
                if (!tegra_host->clk_enabled) {
                        pm_runtime_get_sync(&pdev->dev);
                        clk_prepare_enable(pltfm_host->clk);
@@ -1174,19 +1165,6 @@ static void tegra_sdhci_set_clock(struct sdhci_host *sdhci, unsigned int clock)
                clk_disable_unprepare(pltfm_host->clk);
                pm_runtime_put_sync(&pdev->dev);
                tegra_host->clk_enabled = false;
-               /* io dpd enable call for sd instance */
-
-               if (tegra_host->dpd) {
-                       mutex_lock(&tegra_host->dpd->delay_lock);
-                       if (tegra_host->dpd->need_delay_dpd) {
-                               schedule_delayed_work(
-                                       &tegra_host->dpd->delay_dpd,
-                                       msecs_to_jiffies(100));
-                       } else {
-                               tegra_io_dpd_enable(tegra_host->dpd);
-                       }
-                       mutex_unlock(&tegra_host->dpd->delay_lock);
-               }
        }
 }
 static void tegra_sdhci_do_calibration(struct sdhci_host *sdhci)
@@ -2103,12 +2081,6 @@ static int tegra_sdhci_suspend(struct sdhci_host *sdhci)
                }
        }
 
-       if (tegra_host->dpd) {
-               mutex_lock(&tegra_host->dpd->delay_lock);
-               tegra_host->dpd->need_delay_dpd = 1;
-               mutex_unlock(&tegra_host->dpd->delay_lock);
-       }
-
        return 0;
 }
 
@@ -2652,7 +2624,6 @@ static int __devinit sdhci_tegra_probe(struct platform_device *pdev)
        tegra_host->ddr_clk_limit = plat->ddr_clk_limit;
        tegra_host->sd_detect_in_suspend = plat->sd_detect_in_suspend;
        tegra_host->instance = pdev->id;
-       tegra_host->dpd = tegra_io_dpd_get(mmc_dev(host->mmc));
 
        host->mmc->pm_caps |= plat->pm_caps;
        host->mmc->pm_flags |= plat->pm_flags;