summaryrefslogtreecommitdiff
path: root/drivers/regulator/core.c
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2012-12-10 07:42:55 +0400
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-12-10 07:42:55 +0400
commit1f9cc5f7716d664bfe32289ca61327be01a0a8e3 (patch)
tree06b29c20a1d0c195fbf5513fdfb860cb38f09420 /drivers/regulator/core.c
parent207f30894a8469849d9f5663149d966ff4d411e8 (diff)
parent8dc995f56ef7aedb41873fdeaa1971f3aa166ebd (diff)
downloadlinux-1f9cc5f7716d664bfe32289ca61327be01a0a8e3.tar.xz
Merge remote-tracking branch 'regulator/topic/hotplug' into regulator-next
Diffstat (limited to 'drivers/regulator/core.c')
-rw-r--r--drivers/regulator/core.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c
index 59e08633372a..d5f84c1b258b 100644
--- a/drivers/regulator/core.c
+++ b/drivers/regulator/core.c
@@ -2007,6 +2007,11 @@ int regulator_is_supported_voltage(struct regulator *regulator,
return ret;
}
+ /* Any voltage within constrains range is fine? */
+ if (rdev->desc->continuous_voltage_range)
+ return min_uV >= rdev->constraints->min_uV &&
+ max_uV <= rdev->constraints->max_uV;
+
ret = regulator_count_voltages(regulator);
if (ret < 0)
return ret;