mmc: sd: return error information of sd_init_card incase of failure

During _mmc_sd_resume, if sd card initialization fails, the error
information is getting overwritten by mmc_resume_clk_scaling and the
error is not passed to caller function.

Change-Id: Id173e2db65024f12a714ec623668e47c540a56c3
Signed-off-by: Vijay Viswanath <vviswana@codeaurora.org>
This commit is contained in:
Vijay Viswanath 2017-03-22 15:04:24 +05:30 committed by Gerrit - the friendly Code Review server
parent 272879fc1f
commit ddd7309328

View file

@ -1283,6 +1283,11 @@ static int _mmc_sd_resume(struct mmc_host *host)
#else
err = mmc_sd_init_card(host, host->card->ocr, host->card);
#endif
if (err) {
pr_err("%s: %s: mmc_sd_init_card_failed (%d)\n",
mmc_hostname(host), __func__, err);
goto out;
}
mmc_card_clr_suspended(host->card);
if (host->card->sdr104_blocked)