diff options
author | Dmitry Shmidt <dimitrysh@google.com> | 2010-10-07 14:39:16 -0700 |
---|---|---|
committer | Colin Cross <ccross@android.com> | 2012-02-14 11:26:20 -0800 |
commit | 5ac72c80ecc0b708659ccc433c1d2eaaf0707754 (patch) | |
tree | 6a00762c51b0f430618583ab8cf6d5ed27dadf1c /drivers | |
parent | 880857a6e6bf1de9e574c7978430ad00ddb421ce (diff) |
mmc: Add "ignore mmc pm notify" functionality
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/mmc/core/host.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/mmc/core/host.c b/drivers/mmc/core/host.c index 30055f2b0d4..225f87af306 100644 --- a/drivers/mmc/core/host.c +++ b/drivers/mmc/core/host.c @@ -382,7 +382,8 @@ int mmc_add_host(struct mmc_host *host) mmc_host_clk_sysfs_init(host); mmc_start_host(host); - register_pm_notifier(&host->pm_notify); + if (!(host->pm_flags & MMC_PM_IGNORE_PM_NOTIFY)) + register_pm_notifier(&host->pm_notify); return 0; } @@ -399,7 +400,9 @@ EXPORT_SYMBOL(mmc_add_host); */ void mmc_remove_host(struct mmc_host *host) { - unregister_pm_notifier(&host->pm_notify); + if (!(host->pm_flags & MMC_PM_IGNORE_PM_NOTIFY)) + unregister_pm_notifier(&host->pm_notify); + mmc_stop_host(host); #ifdef CONFIG_DEBUG_FS |