]> git.proxmox.com Git - mirror_ubuntu-kernels.git/blobdiff - drivers/regulator/of_regulator.c
Merge remote-tracking branches 'regulator/topic/da9063', 'regulator/topic/doc', ...
[mirror_ubuntu-kernels.git] / drivers / regulator / of_regulator.c
index e952439e0d83dcf20e857d5ded8c75e3da706770..e221cb1ce8edffee78c2342fb6be8d0bd7ba658c 100644 (file)
@@ -58,6 +58,10 @@ static void of_get_regulation_constraints(struct device_node *np,
        if (!of_property_read_u32(np, "regulator-max-microamp", &pval))
                constraints->max_uA = pval;
 
+       if (!of_property_read_u32(np, "regulator-input-current-limit-microamp",
+                                 &pval))
+               constraints->ilim_uA = pval;
+
        /* Current change possible? */
        if (constraints->min_uA != constraints->max_uA)
                constraints->valid_ops_mask |= REGULATOR_CHANGE_CURRENT;
@@ -67,6 +71,8 @@ static void of_get_regulation_constraints(struct device_node *np,
        if (!constraints->always_on) /* status change should be possible. */
                constraints->valid_ops_mask |= REGULATOR_CHANGE_STATUS;
 
+       constraints->pull_down = of_property_read_bool(np, "regulator-pull-down");
+
        if (of_property_read_bool(np, "regulator-allow-bypass"))
                constraints->valid_ops_mask |= REGULATOR_CHANGE_BYPASS;
 
@@ -82,6 +88,9 @@ static void of_get_regulation_constraints(struct device_node *np,
        if (!ret)
                constraints->enable_time = pval;
 
+       constraints->soft_start = of_property_read_bool(np,
+                                       "regulator-soft-start");
+
        if (!of_property_read_u32(np, "regulator-initial-mode", &pval)) {
                if (desc && desc->of_map_mode) {
                        ret = desc->of_map_mode(pval);
@@ -95,6 +104,9 @@ static void of_get_regulation_constraints(struct device_node *np,
                }
        }
 
+       if (!of_property_read_u32(np, "regulator-system-load", &pval))
+               constraints->system_load = pval;
+
        for (i = 0; i < ARRAY_SIZE(regulator_states); i++) {
                switch (i) {
                case PM_SUSPEND_MEM: