Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e4986b0e authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "Revert "mmc: core: rescan for card if deferred resume fails""

parents c77052c5 a203bd76
Loading
Loading
Loading
Loading
+1 −16
Original line number Diff line number Diff line
@@ -3251,22 +3251,7 @@ int mmc_resume_bus(struct mmc_host *host)
	if (host->bus_ops && !host->bus_dead && host->card && card_present) {
		mmc_power_up(host, host->card->ocr);
		BUG_ON(!host->bus_ops->resume);
		err = host->bus_ops->resume(host);
		if (err) {
			pr_err("%s: %s: resume failed: %d\n",
				       mmc_hostname(host), __func__, err);
			/*
			 * If we have cd-gpio based detection mechanism and
			 * deferred resume is supported, we will not detect
			 * card removal event when system is suspended. So if
			 * resume fails after a system suspend/resume,
			 * schedule the work to detect card presence.
			 */
			if (mmc_card_is_removable(host) &&
					!(host->caps & MMC_CAP_NEEDS_POLL)) {
				mmc_detect_change(host, 0);
			}
		}
		host->bus_ops->resume(host);
		if (mmc_card_cmdq(host->card)) {
			err = mmc_cmdq_halt(host, false);
			if (err)
+0 −2
Original line number Diff line number Diff line
@@ -1322,8 +1322,6 @@ static int _mmc_sd_resume(struct mmc_host *host)
			mmc_hostname(host), __func__, err);
		mmc_card_set_removed(host->card);
		mmc_detect_change(host, msecs_to_jiffies(200));
	} else if (err) {
		goto out;
	}
	mmc_card_clr_suspended(host->card);