diff options
Diffstat (limited to 'drivers/regulator/of_regulator.c')
-rw-r--r-- | drivers/regulator/of_regulator.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/drivers/regulator/of_regulator.c b/drivers/regulator/of_regulator.c index 09d677d5d3f0..96bf75458da5 100644 --- a/drivers/regulator/of_regulator.c +++ b/drivers/regulator/of_regulator.c @@ -90,6 +90,25 @@ static void of_get_regulation_constraints(struct device_node *np, if (!ret) constraints->settling_time = pval; + ret = of_property_read_u32(np, "regulator-settling-time-up-us", &pval); + if (!ret) + constraints->settling_time_up = pval; + if (constraints->settling_time_up && constraints->settling_time) { + pr_warn("%s: ambiguous configuration for settling time, ignoring 'regulator-settling-time-up-us'\n", + np->name); + constraints->settling_time_up = 0; + } + + ret = of_property_read_u32(np, "regulator-settling-time-down-us", + &pval); + if (!ret) + constraints->settling_time_down = pval; + if (constraints->settling_time_down && constraints->settling_time) { + pr_warn("%s: ambiguous configuration for settling time, ignoring 'regulator-settling-time-down-us'\n", + np->name); + constraints->settling_time_down = 0; + } + ret = of_property_read_u32(np, "regulator-enable-ramp-delay", &pval); if (!ret) constraints->enable_time = pval; |