Commit 17e9ff55 authored by Seungwon Jeon's avatar Seungwon Jeon Committed by Chris Ball

mmc: core: Add claiming of hosts during mmc_cache_ctrl

While calling mmc_cache_ctrl() a host is not claimed. This patch
adds the mmc_try_claim_host() for quick response in suspend.
Signed-off-by: default avatarSeungwon Jeon <tgih.jun@samsung.com>
Signed-off-by: default avatarChris Ball <cjb@laptop.org>
parent d83b6e03
......@@ -2355,7 +2355,13 @@ int mmc_suspend_host(struct mmc_host *host)
cancel_delayed_work(&host->disable);
cancel_delayed_work(&host->detect);
mmc_flush_scheduled_work();
err = mmc_cache_ctrl(host, 0);
if (mmc_try_claim_host(host)) {
err = mmc_cache_ctrl(host, 0);
mmc_do_release_host(host);
} else {
err = -EBUSY;
}
if (err)
goto out;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment