Lines Matching refs:align
26 const struct rail_alignment *align) in round_cvb_voltage() argument
30 int step = (align->step_uv ? : 1000) * v_scale; in round_cvb_voltage()
31 int offset = align->offset_uv * v_scale; in round_cvb_voltage()
34 uv = DIV_ROUND_UP(uv, step) * align->step_uv + align->offset_uv; in round_cvb_voltage()
43 static int round_voltage(int mv, const struct rail_alignment *align, int up) in round_voltage() argument
45 if (align->step_uv) { in round_voltage()
48 uv = max(mv * 1000, align->offset_uv) - align->offset_uv; in round_voltage()
49 uv = (uv + (up ? align->step_uv - 1 : 0)) / align->step_uv; in round_voltage()
50 return (uv * align->step_uv + align->offset_uv) / 1000; in round_voltage()
56 struct rail_alignment *align, in build_opp_table() argument
61 min_mv = round_voltage(table->min_millivolts, align, UP); in build_opp_table()
62 max_mv = round_voltage(table->max_millivolts, align, DOWN); in build_opp_table()
73 align); in build_opp_table()
104 size_t count, struct rail_alignment *align, in tegra_cvb_add_opp_table() argument
120 ret = build_opp_table(dev, table, align, speedo_value, in tegra_cvb_add_opp_table()