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

Commit a94c8b39 authored by Veerabhadrarao Badiganti's avatar Veerabhadrarao Badiganti Committed by Gerrit - the friendly Code Review server
Browse files

mmc: core: Return card status if sdr104_wa is not present



On the targets in which sdr104 workaround is not needed, simply return
card status from mmc_recovery_fallback_lower_speed() call.

If any platform uses the tray for SD card, then even if the tray is
inserted without sd card, card-detect gpio pulled low. And in card
removal detection path we end-up in calling
mmc_recovery_fallback_lower_speed(). If we don't return error or card
status it may treat errors are due to CRC errors and try to fall-back to
lower speed mode instead of marking the card as removed.

Change-Id: I83a41c44f5b031663733d7ffa226c1feaa5c9203
Signed-off-by: default avatarVeerabhadrarao Badiganti <vbadigan@codeaurora.org>
parent 60733446
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -468,6 +468,9 @@ int mmc_recovery_fallback_lower_speed(struct mmc_host *host)
		mmc_host_clear_sdr104(host);
		err = mmc_hw_reset(host);
		host->card->sdr104_blocked = true;
	} else {
		/* If sdr104_wa is not present, just return status */
		err = host->bus_ops->alive(host);
	}
	if (err)
		pr_err("%s: %s: Fallback to lower speed mode failed with err=%d\n",