From 3097dec9f9e80dbfdbd405ee09508411bae10063 Mon Sep 17 00:00:00 2001 From: Xavier Boudet Date: Thu, 26 Jul 2012 09:41:20 +0200 Subject: Revert "OMAP: HSMMC: Track regulator enabled locally" This reverts commit a3df42492aa8c216e83ca9dd5f537c24de0089a8. --- drivers/mmc/host/omap_hsmmc.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'drivers') diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c index cb95f2c747c4..6937ad56825d 100644 --- a/drivers/mmc/host/omap_hsmmc.c +++ b/drivers/mmc/host/omap_hsmmc.c @@ -287,13 +287,12 @@ static int omap_hsmmc_1_set_power(struct device *dev, int slot, int power_on, if (host->vcc_aux && !host->regulator_enabled && !ret) { ret = regulator_enable(host->vcc_aux); - if (!ret) { + if (!ret) host->regulator_enabled = 1; msleep(100); - } } } else { - if (host->vcc_aux && host->regulator_enabled) { + if (host->vcc_aux && regulator_is_enabled(host->vcc_aux) > 0) { ret = regulator_disable(host->vcc_aux); if (!ret) host->regulator_enabled = 0; -- cgit v1.2.3