Lines Matching full:limits
43 * @limits: constraints for charger, matching the MBCICHWRC register
54 * - is always between <limits.min, limits.max>;
60 * is outside of given charger limits) and 'dst' is not set.
62 int maxim_charger_calc_reg_current(const struct maxim_charger_current *limits, in maxim_charger_calc_reg_current() argument
70 if (min_ua > limits->max || max_ua < limits->min) in maxim_charger_calc_reg_current()
73 if (max_ua < limits->high_start) { in maxim_charger_calc_reg_current()
82 /* max_ua is in range: <high_start, infinite>, cut it to limits.max */ in maxim_charger_calc_reg_current()
83 max_ua = min(limits->max, max_ua); in maxim_charger_calc_reg_current()
84 max_ua -= limits->high_start; in maxim_charger_calc_reg_current()
87 * - max_ua >= limits.high_start in maxim_charger_calc_reg_current()
88 * - BUILD_BUG checks that 'limits' are: max >= high_start + high_step in maxim_charger_calc_reg_current()
90 current_bits = max_ua / limits->high_step; in maxim_charger_calc_reg_current()
92 /* Turn Low Bit on (use range <limits.high_start, limits.max>) ... */ in maxim_charger_calc_reg_current()