diff options
Diffstat (limited to 'drivers/regulator')
-rw-r--r-- | drivers/regulator/core.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c index 2f14c16f58c3..98c3a74e9949 100644 --- a/drivers/regulator/core.c +++ b/drivers/regulator/core.c | |||
@@ -703,10 +703,13 @@ static int set_machine_constraints(struct regulator_dev *rdev, | |||
703 | int cmin = constraints->min_uV; | 703 | int cmin = constraints->min_uV; |
704 | int cmax = constraints->max_uV; | 704 | int cmax = constraints->max_uV; |
705 | 705 | ||
706 | /* it's safe to autoconfigure fixed-voltage supplies */ | 706 | /* it's safe to autoconfigure fixed-voltage supplies |
707 | and the constraints are used by list_voltage. */ | ||
707 | if (count == 1 && !cmin) { | 708 | if (count == 1 && !cmin) { |
708 | cmin = INT_MIN; | 709 | cmin = 1; |
709 | cmax = INT_MAX; | 710 | cmax = INT_MAX; |
711 | constraints->min_uV = cmin; | ||
712 | constraints->max_uV = cmax; | ||
710 | } | 713 | } |
711 | 714 | ||
712 | /* voltage constraints are optional */ | 715 | /* voltage constraints are optional */ |