mirror of
https://github.com/rd-stuffs/msm-4.14.git
synced 2025-02-20 11:45:48 +08:00
mmc: core: Invoke mmc_power_up/off with claim_host acquired
mmc_power_up/off() would be processed by the platform driver, so we should ensure that platform driver is in resume state before invoking these calls. Acquire mmc_claim_host before invoking mmc_power_up/off() which explicitly resumes platform device. In prior version kernels, platform device was getting resumed in mmc_set_ios which gets called by mmc_power_up/down(). But on 4.9 onwards, it was consolidated and added in mmc_claim_host(). So this requirement has arisen only here. Change-Id: I548bd55e41465a84472081542446b036ebd877a0 Signed-off-by: Veerabhadrarao Badiganti <vbadigan@codeaurora.org>
This commit is contained in:
parent
ae56b6a5c4
commit
8a1f0c2093
@ -4472,7 +4472,9 @@ int mmc_power_save_host(struct mmc_host *host)
|
||||
|
||||
mmc_bus_put(host);
|
||||
|
||||
mmc_claim_host(host);
|
||||
mmc_power_off(host);
|
||||
mmc_release_host(host);
|
||||
|
||||
return ret;
|
||||
}
|
||||
@ -4491,8 +4493,8 @@ int mmc_power_restore_host(struct mmc_host *host)
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
mmc_power_up(host, host->card->ocr);
|
||||
mmc_claim_host(host);
|
||||
mmc_power_up(host, host->card->ocr);
|
||||
ret = host->bus_ops->power_restore(host);
|
||||
mmc_release_host(host);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user