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

Commit 19496d20 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "mmc: sdhci-msm: Don't turnoff Vcc during initialization"

parents ba23552f eed1deac
Loading
Loading
Loading
Loading
+6 −17
Original line number Diff line number Diff line
@@ -2345,21 +2345,6 @@ static int sdhci_msm_setup_vreg(struct sdhci_msm_pltfm_data *pdata,
	return ret;
}

/*
 * Reset vreg by ensuring it is off during probe. A call
 * to enable vreg is needed to balance disable vreg
 */
static int sdhci_msm_vreg_reset(struct sdhci_msm_pltfm_data *pdata)
{
	int ret;

	ret = sdhci_msm_setup_vreg(pdata, 1, true);
	if (ret)
		return ret;
	ret = sdhci_msm_setup_vreg(pdata, 0, true);
	return ret;
}

/* This init function should be called only once for each SDHC slot */
static int sdhci_msm_vreg_init(struct device *dev,
				struct sdhci_msm_pltfm_data *pdata,
@@ -2394,7 +2379,7 @@ static int sdhci_msm_vreg_init(struct device *dev,
		if (ret)
			goto vdd_reg_deinit;
	}
	ret = sdhci_msm_vreg_reset(pdata);

	if (ret)
		dev_err(dev, "vreg reset failed (%d)\n", ret);
	goto out;
@@ -2571,7 +2556,9 @@ static irqreturn_t sdhci_msm_pwr_irq(int irq, void *data)
		io_level = REQ_IO_HIGH;
	}
	if (irq_status & CORE_PWRCTL_BUS_OFF) {
		ret = sdhci_msm_setup_vreg(msm_host->pdata, false, false);
		if (msm_host->pltfm_init_done)
			ret = sdhci_msm_setup_vreg(msm_host->pdata,
					false, false);
		if (!ret) {
			ret = sdhci_msm_setup_pins(msm_host->pdata, false);
			ret |= sdhci_msm_set_vdd_io_vol(msm_host->pdata,
@@ -4512,6 +4499,8 @@ static int sdhci_msm_probe(struct platform_device *pdev)
		goto vreg_deinit;
	}

	msm_host->pltfm_init_done = true;

	pm_runtime_set_active(&pdev->dev);
	pm_runtime_enable(&pdev->dev);
	pm_runtime_set_autosuspend_delay(&pdev->dev, MSM_AUTOSUSPEND_DELAY_MS);
+1 −0
Original line number Diff line number Diff line
@@ -225,6 +225,7 @@ struct sdhci_msm_host {
	bool mci_removed;
	const struct sdhci_msm_offset *offset;
	bool core_3_0v_support;
	bool pltfm_init_done;
};

extern char *saved_command_line;