diff mbox

regulator: core: Keep boot_on regulators powered during init

Message ID 1335173873-24301-1-git-send-email-ulf.hansson@stericsson.com
State New
Headers show

Commit Message

Ulf Hansson April 23, 2012, 9:37 a.m. UTC
Regulators which has boot_on constraints set, will now remain
powered after regulator_init_complete is done.

In this case we leave the enable->disable operation to be
handled by the regulator consumer instead.

Signed-off-by: Ulf Hansson <ulf.hansson@stericsson.com>
---
 drivers/regulator/core.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff mbox

Patch

diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c
index 1caada2..c5af6d2 100644
--- a/drivers/regulator/core.c
+++ b/drivers/regulator/core.c
@@ -3393,7 +3393,7 @@  static int __init regulator_init_complete(void)
 		ops = rdev->desc->ops;
 		c = rdev->constraints;
 
-		if (!ops->disable || (c && c->always_on))
+		if (!ops->disable || (c && (c->always_on || c->boot_on)))
 			continue;
 
 		mutex_lock(&rdev->mutex);