diff options
author | Ulf Hansson <ulf.hansson@linaro.org> | 2013-05-02 14:02:36 +0200 |
---|---|---|
committer | Chris Ball <cjb@laptop.org> | 2013-05-26 14:23:15 -0400 |
commit | 39b9431b0f371294dd2d1a492cf77f2f17390a1f (patch) | |
tree | 40776c2961dd27dcc7b58becdb86e7ffde0d77ee /drivers/mmc/core/mmc.c | |
parent | 0c5ce16bc11ae3b80d2e3f6caf4483162acb1f62 (diff) |
mmc: core: Stop bkops for eMMC only from mmc suspend
Move mmc suspend specific operations to be executed from the .suspend
callback in the mmc bus_ops. This simplifies the mmc_suspend_host
function which is supposed to handle nothing but common suspend tasks.
Since eMMC can be considered non-removable there are no need to check
for ongoing bkops at PM_SUSPEND_PREPARE notification so remove it.
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Chris Ball <cjb@laptop.org>
Diffstat (limited to 'drivers/mmc/core/mmc.c')
-rw-r--r-- | drivers/mmc/core/mmc.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/mmc/core/mmc.c b/drivers/mmc/core/mmc.c index 0cbd1effe96..a0469cf7933 100644 --- a/drivers/mmc/core/mmc.c +++ b/drivers/mmc/core/mmc.c @@ -1411,6 +1411,12 @@ static int mmc_suspend(struct mmc_host *host) mmc_claim_host(host); + if (mmc_card_doing_bkops(host->card)) { + err = mmc_stop_bkops(host->card); + if (err) + goto out; + } + err = mmc_cache_ctrl(host, 0); if (err) goto out; |