Lines Matching refs:min_uV
107 int min_uV, int max_uV);
259 int *min_uV, int *max_uV) in regulator_check_voltage() argument
261 BUG_ON(*min_uV > *max_uV); in regulator_check_voltage()
270 if (*min_uV < rdev->constraints->min_uV) in regulator_check_voltage()
271 *min_uV = rdev->constraints->min_uV; in regulator_check_voltage()
273 if (*min_uV > *max_uV) { in regulator_check_voltage()
275 *min_uV, *max_uV); in regulator_check_voltage()
292 int *min_uV, int *max_uV, in regulator_check_consumers() argument
304 if (!voltage->min_uV && !voltage->max_uV) in regulator_check_consumers()
309 if (*min_uV < voltage->min_uV) in regulator_check_consumers()
310 *min_uV = voltage->min_uV; in regulator_check_consumers()
313 if (*min_uV > *max_uV) { in regulator_check_consumers()
315 *min_uV, *max_uV); in regulator_check_consumers()
556 return sprintf(buf, "%d\n", rdev->constraints->min_uV); in regulator_min_uV_show()
866 if (constraints->min_uV && constraints->max_uV) { in print_constraints()
867 if (constraints->min_uV == constraints->max_uV) in print_constraints()
869 constraints->min_uV / 1000); in print_constraints()
873 constraints->min_uV / 1000, in print_constraints()
877 if (!constraints->min_uV || in print_constraints()
878 constraints->min_uV != constraints->max_uV) { in print_constraints()
922 if ((constraints->min_uV != constraints->max_uV) && in print_constraints()
936 rdev->constraints->min_uV && rdev->constraints->max_uV) { in machine_constraints_voltage()
943 rdev->constraints->min_uV, in machine_constraints_voltage()
946 rdev->constraints->min_uV, in machine_constraints_voltage()
966 if (current_uV < rdev->constraints->min_uV) { in machine_constraints_voltage()
967 target_min = rdev->constraints->min_uV; in machine_constraints_voltage()
968 target_max = rdev->constraints->min_uV; in machine_constraints_voltage()
996 int min_uV = INT_MAX; in machine_constraints_voltage() local
998 int cmin = constraints->min_uV; in machine_constraints_voltage()
1006 constraints->min_uV = cmin; in machine_constraints_voltage()
1029 if (value >= cmin && value < min_uV) in machine_constraints_voltage()
1030 min_uV = value; in machine_constraints_voltage()
1036 if (max_uV < min_uV) { in machine_constraints_voltage()
1039 min_uV, max_uV); in machine_constraints_voltage()
1044 if (constraints->min_uV < min_uV) { in machine_constraints_voltage()
1046 constraints->min_uV, min_uV); in machine_constraints_voltage()
1047 constraints->min_uV = min_uV; in machine_constraints_voltage()
1424 ®ulator->voltage[PM_SUSPEND_ON].min_uV); in create_regulator()
2567 if (ret < rdev->constraints->min_uV) in _regulator_list_voltage()
2737 int min_uV, int max_uV) in regulator_is_supported_voltage() argument
2746 return min_uV <= ret && ret <= max_uV; in regulator_is_supported_voltage()
2753 return min_uV >= rdev->constraints->min_uV && in regulator_is_supported_voltage()
2764 if (ret >= min_uV && ret <= max_uV) in regulator_is_supported_voltage()
2772 static int regulator_map_voltage(struct regulator_dev *rdev, int min_uV, in regulator_map_voltage() argument
2778 return desc->ops->map_voltage(rdev, min_uV, max_uV); in regulator_map_voltage()
2781 return regulator_map_voltage_linear(rdev, min_uV, max_uV); in regulator_map_voltage()
2784 return regulator_map_voltage_linear_range(rdev, min_uV, max_uV); in regulator_map_voltage()
2786 return regulator_map_voltage_iterate(rdev, min_uV, max_uV); in regulator_map_voltage()
2790 int min_uV, int max_uV, in _regulator_call_set_voltage() argument
2797 data.min_uV = min_uV; in _regulator_call_set_voltage()
2804 ret = rdev->desc->ops->set_voltage(rdev, min_uV, max_uV, selector); in _regulator_call_set_voltage()
2821 data.min_uV = uV; in _regulator_call_set_voltage_sel()
2865 int min_uV, int max_uV) in _regulator_do_set_voltage() argument
2875 trace_regulator_set_voltage(rdev_get_name(rdev), min_uV, max_uV); in _regulator_do_set_voltage()
2877 min_uV += rdev->constraints->uV_offset; in _regulator_do_set_voltage()
2892 ret = _regulator_call_set_voltage(rdev, min_uV, max_uV, in _regulator_do_set_voltage()
2904 ret = regulator_map_voltage(rdev, min_uV, max_uV); in _regulator_do_set_voltage()
2907 if (min_uV <= best_val && max_uV >= best_val) { in _regulator_do_set_voltage()
2972 int min_uV, int max_uV, suspend_state_t state) in _regulator_do_set_suspend_voltage() argument
2981 if (min_uV < rstate->min_uV) in _regulator_do_set_suspend_voltage()
2982 min_uV = rstate->min_uV; in _regulator_do_set_suspend_voltage()
2986 sel = regulator_map_voltage(rdev, min_uV, max_uV); in _regulator_do_set_suspend_voltage()
2991 if (uV >= min_uV && uV <= max_uV) in _regulator_do_set_suspend_voltage()
2998 int min_uV, int max_uV, in regulator_set_voltage_unlocked() argument
3013 if (voltage->min_uV == min_uV && voltage->max_uV == max_uV) in regulator_set_voltage_unlocked()
3022 if (min_uV <= current_uV && current_uV <= max_uV) { in regulator_set_voltage_unlocked()
3023 voltage->min_uV = min_uV; in regulator_set_voltage_unlocked()
3037 ret = regulator_check_voltage(rdev, &min_uV, &max_uV); in regulator_set_voltage_unlocked()
3042 old_min_uV = voltage->min_uV; in regulator_set_voltage_unlocked()
3044 voltage->min_uV = min_uV; in regulator_set_voltage_unlocked()
3047 ret = regulator_check_consumers(rdev, &min_uV, &max_uV, state); in regulator_set_voltage_unlocked()
3059 selector = regulator_map_voltage(rdev, min_uV, max_uV); in regulator_set_voltage_unlocked()
3093 ret = _regulator_do_set_voltage(rdev, min_uV, max_uV); in regulator_set_voltage_unlocked()
3095 ret = _regulator_do_set_suspend_voltage(rdev, min_uV, in regulator_set_voltage_unlocked()
3113 voltage->min_uV = old_min_uV; in regulator_set_voltage_unlocked()
3137 int regulator_set_voltage(struct regulator *regulator, int min_uV, int max_uV) in regulator_set_voltage() argument
3143 ret = regulator_set_voltage_unlocked(regulator, min_uV, max_uV, in regulator_set_voltage()
3188 if (voltage->min_uV || voltage->max_uV) in regulator_suspend_disable()
3197 int min_uV, int max_uV, in _regulator_set_suspend_voltage() argument
3207 if (rstate->min_uV == rstate->max_uV) { in _regulator_set_suspend_voltage()
3212 return regulator_set_voltage_unlocked(regulator, min_uV, max_uV, state); in _regulator_set_suspend_voltage()
3215 int regulator_set_suspend_voltage(struct regulator *regulator, int min_uV, in regulator_set_suspend_voltage() argument
3226 ret = _regulator_set_suspend_voltage(regulator, min_uV, in regulator_set_suspend_voltage()
3329 int ret, min_uV, max_uV; in regulator_sync_voltage() local
3340 if (!voltage->min_uV && !voltage->max_uV) { in regulator_sync_voltage()
3345 min_uV = voltage->min_uV; in regulator_sync_voltage()
3349 ret = regulator_check_voltage(rdev, &min_uV, &max_uV); in regulator_sync_voltage()
3353 ret = regulator_check_consumers(rdev, &min_uV, &max_uV, 0); in regulator_sync_voltage()
3357 ret = _regulator_do_set_voltage(rdev, min_uV, max_uV); in regulator_sync_voltage()
4690 c->min_uV / 1000, c->max_uV / 1000); in regulator_summary_show_subtree()
4713 consumer->voltage[PM_SUSPEND_ON].min_uV / 1000, in regulator_summary_show_subtree()