/openbmc/linux/drivers/mmc/core/ |
H A D | regulator.c | 22 * @max_uV: maximum voltage value (mV) 27 static int mmc_ocrbitnum_to_vdd(int vdd_bit, int *min_uV, int *max_uV) in mmc_ocrbitnum_to_vdd() argument 43 *max_uV = 1950 * 1000; in mmc_ocrbitnum_to_vdd() 46 *max_uV = *min_uV + 100 * 1000; in mmc_ocrbitnum_to_vdd() 111 int min_uV, max_uV; in mmc_regulator_set_ocr() local 117 mmc_ocrbitnum_to_vdd(vdd_bit, &min_uV, &max_uV); in mmc_regulator_set_ocr() 119 result = regulator_set_voltage(supply, min_uV, max_uV); in mmc_regulator_set_ocr() 140 int max_uV) in mmc_regulator_set_voltage_if_supported() argument 148 if (!regulator_is_supported_voltage(regulator, min_uV, max_uV)) in mmc_regulator_set_voltage_if_supported() 160 max_uV); in mmc_regulator_set_voltage_if_supported() [all …]
|
/openbmc/linux/include/linux/regulator/ |
H A D | coupler.h | 56 int *min_uV, int *max_uV, 59 int *min_uV, int *max_uV); 62 int min_uV, int max_uV, 72 int *min_uV, int *max_uV, in regulator_check_consumers() argument 78 int *min_uV, int *max_uV) in regulator_check_voltage() argument 87 int min_uV, int max_uV, in regulator_set_voltage_rdev() argument
|
H A D | consumer.h | 161 * @max_uV: Max voltage we'll change to. 166 unsigned long max_uV; member 272 int min_uV, int max_uV); 274 int regulator_set_voltage(struct regulator *regulator, int min_uV, int max_uV); 314 int max_uV, suspend_state_t state); 531 int min_uV, int max_uV) in regulator_set_voltage() argument 553 int min_uV, int max_uV) in regulator_is_supported_voltage() argument 657 int min_uV, int max_uV, in regulator_set_suspend_voltage() argument 699 int max_uV) in regulator_set_voltage_triplet() argument 701 if (regulator_set_voltage(regulator, target_uV, max_uV) == 0) in regulator_set_voltage_triplet() [all …]
|
H A D | machine.h | 67 * among <min_uV, max_uV>. 69 * @max_uV: Maximum suspend voltage may be set. 80 int max_uV; member 102 * @max_uV: Largest voltage consumers may set. 163 int max_uV; member
|
/openbmc/linux/drivers/platform/x86/intel/int3472/ |
H A D | tps68470_board_data.c | 47 .max_uV = 1200000, 58 .max_uV = 2815200, 69 .max_uV = 2815200, 81 .max_uV = 1800600, 90 .max_uV = 1800600, 101 .max_uV = 2815200, 112 .max_uV = 1800600,
|
/openbmc/linux/drivers/regulator/ |
H A D | core.c | 92 int min_uV, int max_uV); 488 int *min_uV, int *max_uV) in regulator_check_voltage() argument 490 BUG_ON(*min_uV > *max_uV); in regulator_check_voltage() 497 if (*max_uV > rdev->constraints->max_uV) in regulator_check_voltage() 498 *max_uV = rdev->constraints->max_uV; in regulator_check_voltage() 502 if (*min_uV > *max_uV) { in regulator_check_voltage() 504 *min_uV, *max_uV); in regulator_check_voltage() 521 int *min_uV, int *max_uV, in regulator_check_consumers() argument 533 if (!voltage->min_uV && !voltage->max_uV) in regulator_check_consumers() 536 if (*max_uV > voltage->max_uV) in regulator_check_consumers() [all …]
|
H A D | virtual.c | 23 int max_uV; member 34 if (data->min_uV && data->max_uV in update_voltage_constraints() 35 && data->min_uV <= data->max_uV) { in update_voltage_constraints() 37 data->min_uV, data->max_uV); in update_voltage_constraints() 39 data->min_uV, data->max_uV); in update_voltage_constraints() 47 if (data->min_uV && data->max_uV && !data->enabled) { in update_voltage_constraints() 57 if (!(data->min_uV && data->max_uV) && data->enabled) { in update_voltage_constraints() 138 return sprintf(buf, "%d\n", data->max_uV); in show_max_uV() 152 data->max_uV = val; in set_max_uV()
|
H A D | vctrl-regulator.c | 23 int max_uV; member 55 (ctrl->max_uV - ctrl->min_uV), in vctrl_calc_ctrl_voltage() 56 out->max_uV - out->min_uV); in vctrl_calc_ctrl_voltage() 72 if (ctrl_uV > ctrl->max_uV) in vctrl_calc_output_voltage() 73 return out->max_uV; in vctrl_calc_output_voltage() 77 (out->max_uV - out->min_uV), in vctrl_calc_output_voltage() 78 ctrl->max_uV - ctrl->min_uV); in vctrl_calc_output_voltage() 292 vctrl->vrange.out.max_uV = pval; in vctrl_parse_dt() 309 vctrl->vrange.ctrl.max_uV = vrange_ctrl[1]; in vctrl_parse_dt() 341 ctrl_uV > vrange_ctrl->max_uV) in vctrl_init_vtable() [all …]
|
H A D | ab8500-ext.c | 53 .max_uV = 1800000, 64 .max_uV = 1360000, 72 .max_uV = 3400000, 287 int max_uV, unsigned *selector) in ab8500_ext_set_voltage() argument 297 regu_constraints->max_uV == max_uV) in ab8500_ext_set_voltage() 302 min_uV, max_uV, in ab8500_ext_set_voltage() 303 regu_constraints->min_uV, regu_constraints->max_uV); in ab8500_ext_set_voltage() 318 if (regu_constraints->min_uV && regu_constraints->max_uV) { in ab8500_ext_list_voltage() 319 if (regu_constraints->min_uV == regu_constraints->max_uV) in ab8500_ext_list_voltage()
|
H A D | helpers.c | 305 * @max_uV: Upper bound for voltage 313 int min_uV, int max_uV) in regulator_map_voltage_iterate() argument 327 if (ret < best_val && ret >= min_uV && ret <= max_uV) { in regulator_map_voltage_iterate() 345 * @max_uV: Upper bound for voltage 351 int min_uV, int max_uV) in regulator_map_voltage_ascend() argument 360 if (ret > max_uV) in regulator_map_voltage_ascend() 363 if (ret >= min_uV && ret <= max_uV) in regulator_map_voltage_ascend() 376 * @max_uV: Upper bound for voltage 382 int min_uV, int max_uV) in regulator_map_voltage_linear() argument 388 if (min_uV <= rdev->desc->min_uV && rdev->desc->min_uV <= max_uV) in regulator_map_voltage_linear() [all …]
|
H A D | pwm-regulator.c | 152 int max_uV = rdev->constraints->max_uV; in pwm_regulator_get_voltage() local 153 int diff_uV = max_uV - min_uV; in pwm_regulator_get_voltage() 166 * The dutycycle for min_uV might be greater than the one for max_uV. in pwm_regulator_get_voltage() 192 int max_uV = rdev->constraints->max_uV; in pwm_regulator_set_voltage() local 193 int diff_uV = max_uV - min_uV; in pwm_regulator_set_voltage() 202 * The dutycycle for min_uV might be greater than the one for max_uV. in pwm_regulator_set_voltage()
|
H A D | da903x-regulator.c | 75 int max_uV; member 91 int min_uV, int max_uV) in check_range() argument 93 if (min_uV < info->desc.min_uV || min_uV > info->max_uV) in check_range() 190 int min_uV, int max_uV) in da9030_map_ldo14_voltage() argument 195 if (check_range(info, min_uV, max_uV)) { in da9030_map_ldo14_voltage() 196 pr_err("invalid voltage range (%d, %d) uV\n", min_uV, max_uV); in da9030_map_ldo14_voltage() 200 thresh = (info->max_uV + info->desc.min_uV) / 2; in da9030_map_ldo14_voltage() 221 volt = (info->max_uV + rdev->desc->min_uV) / 2 + in da9030_list_ldo14_voltage() 224 if (volt > info->max_uV) in da9030_list_ldo14_voltage() 321 .max_uV = (max) * 1000, \ [all …]
|
H A D | da9052-regulator.c | 64 int max_uV; member 75 int min_uV, int max_uV) in verify_range() argument 77 if (min_uV > info->max_uV || max_uV < info->min_uV) in verify_range() 168 if (volt_uV > info->max_uV) in da9052_list_voltage() 175 int min_uV, int max_uV) in da9052_map_voltage() argument 182 ret = verify_range(info, min_uV, max_uV); in da9052_map_voltage() 303 .max_uV = (max) * 1000,\ 325 .max_uV = (max) * 1000,\
|
H A D | mc13xxx-regulator-core.c | 113 int max_uV, unsigned *selector) in mc13xxx_fixed_regulator_set_voltage() argument 117 dev_dbg(rdev_get_dev(rdev), "%s id: %d min_uV: %d max_uV: %d\n", in mc13xxx_fixed_regulator_set_voltage() 118 __func__, id, min_uV, max_uV); in mc13xxx_fixed_regulator_set_voltage() 121 rdev->desc->volt_table[0] <= max_uV) { in mc13xxx_fixed_regulator_set_voltage()
|
H A D | pv88090-regulator.c | 47 int max_uV; member 74 .max_uV = 1393750, 80 .max_uV = 2193750, 85 .max_uV = 2837500, 365 = ((pv88090_buck_vol[index].max_uV) in pv88090_i2c_probe()
|
H A D | cros-ec-regulator.c | 93 int max_uV, unsigned int *selector) in cros_ec_regulator_set_voltage() argument 97 int max_mV = max_uV / 1000; in cros_ec_regulator_set_voltage() 105 * This can happen when the given range [min_uV, max_uV] doesn't in cros_ec_regulator_set_voltage()
|
H A D | vexpress-regulator.c | 27 int min_uV, int max_uV, unsigned *selector) in vexpress_regulator_set_voltage() argument 68 if (init_data->constraints.min_uV && init_data->constraints.max_uV) in vexpress_regulator_probe()
|
H A D | qcom_spmi-regulator.c | 368 * @max_uV: Maximum programmable output voltage 380 * (max_uV - min_uV) % step_uV == 0 390 int max_uV; member 472 .max_uV = _max_uV, \ 667 int min_uV, int max_uV) in spmi_regulator_select_voltage() argument 679 if (uV < lim_min_uV && max_uV >= lim_min_uV) in spmi_regulator_select_voltage() 685 min_uV, max_uV, lim_min_uV, lim_max_uV); in spmi_regulator_select_voltage() 706 if (uV > max_uV) { in spmi_regulator_select_voltage() 710 min_uV, max_uV, uV); in spmi_regulator_select_voltage() 804 int min_uV, int max_uV) in spmi_regulator_select_voltage_same_range() argument [all …]
|
/openbmc/linux/drivers/pmdomain/qcom/ |
H A D | cpr.c | 141 int max_uV; member 202 int max_uV; member 214 int max_uV; member 320 if (cpr_is_allowed(drv) && corner->max_uV > corner->min_uV) in cpr_ctl_enable() 494 if (last_uV >= corner->max_uV) { in cpr_scale() 514 new_uV = min(new_uV, corner->max_uV); in cpr_scale() 878 fdata->max_uV = roundup(fdata->max_uV, step_volt); in cpr_fuse_corner_init() 887 fuse->max_uV = fdata->max_uV; in cpr_fuse_corner_init() 888 fuse->uV = clamp(uV, fuse->min_uV, fuse->max_uV); in cpr_fuse_corner_init() 897 end->max_uV = max(end->max_uV, end->uV); in cpr_fuse_corner_init() [all …]
|
/openbmc/linux/drivers/gpu/drm/nouveau/nvkm/subdev/volt/ |
H A D | base.c | 54 int i, ret = -EINVAL, best_err = volt->max_uv, best = -1; in nvkm_volt_set() 199 volt->max_uv = info.max; in nvkm_volt_parse_bios() 213 volt->max_uv = 0; in nvkm_volt_parse_bios() 222 volt->max_uv = max(volt->max_uv, ivid.voltage); in nvkm_volt_parse_bios() 228 volt->max_uv = info.base + info.pwm_range; in nvkm_volt_parse_bios() 299 volt->min_uv, volt->max_uv); in nvkm_volt_ctor()
|
/openbmc/linux/drivers/soc/mediatek/ |
H A D | mtk-regulator-coupler.c | 39 int vsram_max_uV = mrc->vsram_rdev->constraints->max_uV; in mediatek_regulator_balance_voltage() 42 int max_uV = INT_MAX; in mediatek_regulator_balance_voltage() local 61 ret = regulator_check_consumers(rdev, &min_uV, &max_uV, state); in mediatek_regulator_balance_voltage() 72 ret = regulator_check_voltage(rdev, &min_uV, &max_uV); in mediatek_regulator_balance_voltage()
|
/openbmc/u-boot/drivers/power/regulator/ |
H A D | pwm_regulator.c | 51 int max_uV = priv->max_voltage; in pwm_voltage_to_duty_cycle_percentage() local 52 int diff = max_uV - min_uV; in pwm_voltage_to_duty_cycle_percentage() 129 priv->max_voltage = uc_pdata->max_uV; in pwm_regulator_probe()
|
H A D | regulator-uclass.c | 58 if (uc_pdata->max_uV != -ENODATA && uV > uc_pdata->max_uV) in regulator_set_value() 371 uc_pdata->max_uV = dev_read_u32_default(dev, "regulator-max-microvolt", in regulator_pre_probe() 384 (uc_pdata->max_uV != -ENODATA) && in regulator_pre_probe() 385 (uc_pdata->min_uV == uc_pdata->max_uV)) in regulator_pre_probe()
|
/openbmc/linux/drivers/mmc/host/ |
H A D | dw_mmc-k3.c | 146 int min_uv, max_uv; in dw_mci_hi6220_switch_voltage() local 159 max_uv = 3000000; in dw_mci_hi6220_switch_voltage() 164 max_uv = 1800000; in dw_mci_hi6220_switch_voltage() 178 ret = regulator_set_voltage(mmc->supply.vqmmc, min_uv, max_uv); in dw_mci_hi6220_switch_voltage() 181 ret, min_uv, max_uv); in dw_mci_hi6220_switch_voltage()
|
/openbmc/linux/Documentation/power/regulator/ |
H A D | machine.rst | 45 .max_uV = 3300000, 67 .max_uV = 2000000,
|