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

Commit 5f035ccf authored by Ritesh Harjani's avatar Ritesh Harjani
Browse files

mmc: core: Fix mmc_set_ios w.r.t. error handling sequence



In case of error, software may power cycle/reset both
controller and card. Thus even if auto bkops is enabled,
mmc_set_ios can be used to power-off/power-on.

Fix this by removing this condition from mmc_set_ios.

Change-Id: I88a610ecbcc4036ac8ba99bc54706243b40db391
Signed-off-by: default avatarRitesh Harjani <riteshh@codeaurora.org>
parent 92a91e98
Loading
Loading
Loading
Loading
+0 −7
Original line number Diff line number Diff line
@@ -2056,13 +2056,6 @@ void mmc_set_ios(struct mmc_host *host)
{
	struct mmc_ios *ios = &host->ios;

	if (unlikely(ios->power_mode == MMC_POWER_OFF &&
		     host->card && mmc_card_doing_auto_bkops(host->card))) {
		pr_err("%s: %s: illegal to disable power to card when running auto bkops\n",
				mmc_hostname(host), __func__);
		return;
	}

	pr_debug("%s: clock %uHz busmode %u powermode %u cs %u Vdd %u "
		"width %u timing %u\n",
		 mmc_hostname(host), ios->clock, ios->bus_mode,