Skip to content

Commit b13d2f3

Browse files
committed
Revert "reboot or power-off stage kernel will panic because NPE remove the code avoid kernel panic"
This reverts commit 74fa754. Change-Id: Ib1883bf6af6a286a6b4f300bfb475a1cfac96056 Reviewed-on: https://tp-biosrd-v02/gerrit/80608 Reviewed-by: Alex Cheng(鄭富元) <Alex_Cheng@asus.com> Tested-by: Alex Cheng(鄭富元) <Alex_Cheng@asus.com>
1 parent cfe2329 commit b13d2f3

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

drivers/mmc/host/dw_mmc-rockchip.c

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -289,6 +289,17 @@ static int dw_mci_rockchip_probe(struct platform_device *pdev)
289289

290290
static void dw_mci_rockchip_platfm_shutdown(struct platform_device *pdev)
291291
{
292+
struct dw_mci *host = platform_get_drvdata(pdev);
293+
struct mmc_host *mmc = host->cur_slot->mmc;
294+
int ret;
295+
296+
mdelay(20);
297+
298+
if (!IS_ERR(mmc->supply.vmmc))
299+
ret = regulator_enable(mmc->supply.vmmc);
300+
301+
if (!IS_ERR(mmc->supply.vqmmc))
302+
regulator_set_voltage(mmc->supply.vqmmc, 3000000, 3300000);
292303
}
293304

294305
#ifdef CONFIG_PM_SLEEP

0 commit comments

Comments
 (0)