|
@@ -1835,8 +1835,7 @@ static int sdhci_start_signal_voltage_switch(struct mmc_host *mmc,
|
|
sdhci_writew(host, ctrl, SDHCI_HOST_CONTROL2);
|
|
sdhci_writew(host, ctrl, SDHCI_HOST_CONTROL2);
|
|
|
|
|
|
if (!IS_ERR(mmc->supply.vqmmc)) {
|
|
if (!IS_ERR(mmc->supply.vqmmc)) {
|
|
- ret = regulator_set_voltage(mmc->supply.vqmmc, 2700000,
|
|
|
|
- 3600000);
|
|
|
|
|
|
+ ret = mmc_regulator_set_vqmmc(mmc, ios);
|
|
if (ret) {
|
|
if (ret) {
|
|
pr_warn("%s: Switching to 3.3V signalling voltage failed\n",
|
|
pr_warn("%s: Switching to 3.3V signalling voltage failed\n",
|
|
mmc_hostname(mmc));
|
|
mmc_hostname(mmc));
|
|
@@ -1859,8 +1858,7 @@ static int sdhci_start_signal_voltage_switch(struct mmc_host *mmc,
|
|
if (!(host->flags & SDHCI_SIGNALING_180))
|
|
if (!(host->flags & SDHCI_SIGNALING_180))
|
|
return -EINVAL;
|
|
return -EINVAL;
|
|
if (!IS_ERR(mmc->supply.vqmmc)) {
|
|
if (!IS_ERR(mmc->supply.vqmmc)) {
|
|
- ret = regulator_set_voltage(mmc->supply.vqmmc,
|
|
|
|
- 1700000, 1950000);
|
|
|
|
|
|
+ ret = mmc_regulator_set_vqmmc(mmc, ios);
|
|
if (ret) {
|
|
if (ret) {
|
|
pr_warn("%s: Switching to 1.8V signalling voltage failed\n",
|
|
pr_warn("%s: Switching to 1.8V signalling voltage failed\n",
|
|
mmc_hostname(mmc));
|
|
mmc_hostname(mmc));
|
|
@@ -1892,8 +1890,7 @@ static int sdhci_start_signal_voltage_switch(struct mmc_host *mmc,
|
|
if (!(host->flags & SDHCI_SIGNALING_120))
|
|
if (!(host->flags & SDHCI_SIGNALING_120))
|
|
return -EINVAL;
|
|
return -EINVAL;
|
|
if (!IS_ERR(mmc->supply.vqmmc)) {
|
|
if (!IS_ERR(mmc->supply.vqmmc)) {
|
|
- ret = regulator_set_voltage(mmc->supply.vqmmc, 1100000,
|
|
|
|
- 1300000);
|
|
|
|
|
|
+ ret = mmc_regulator_set_vqmmc(mmc, ios);
|
|
if (ret) {
|
|
if (ret) {
|
|
pr_warn("%s: Switching to 1.2V signalling voltage failed\n",
|
|
pr_warn("%s: Switching to 1.2V signalling voltage failed\n",
|
|
mmc_hostname(mmc));
|
|
mmc_hostname(mmc));
|