Skip to content

Commit 895fe23

Browse files
committed
regulator: core: Always flag voltage constraints as appliable
Allow the core to always use the voltage constraints to set the voltage on startup. A forthcoming change in that code will ensure that we bring out of constraints voltages into spec with this setting. Signed-off-by: Mark Brown <[email protected]>
1 parent 768e666 commit 895fe23

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

drivers/regulator/of_regulator.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,12 +43,10 @@ static void of_get_regulation_constraints(struct device_node *np,
4343
constraints->max_uV = pval;
4444

4545
/* Voltage change possible? */
46-
if (constraints->min_uV != constraints->max_uV)
46+
if (constraints->min_uV != constraints->max_uV) {
4747
constraints->valid_ops_mask |= REGULATOR_CHANGE_VOLTAGE;
48-
/* Only one voltage? Then make sure it's set. */
49-
if (constraints->min_uV && constraints->max_uV &&
50-
constraints->min_uV == constraints->max_uV)
5148
constraints->apply_uV = true;
49+
}
5250

5351
if (!of_property_read_u32(np, "regulator-microvolt-offset", &pval))
5452
constraints->uV_offset = pval;

0 commit comments

Comments
 (0)