Searched refs:voltage_uv (Results 1 - 11 of 11) sorted by relevance

/linux-master/drivers/iio/dac/
H A Dad5624r_spi.c226 int ret, voltage_uv = 0; local
242 voltage_uv = ret;
257 voltage_uv = ret;
265 if (voltage_uv)
266 st->vref_mv = voltage_uv / 1000;
279 !!voltage_uv, 16);
H A Dad5686.c459 int ret, i, voltage_uv = 0; local
482 voltage_uv = ret;
487 if (voltage_uv)
488 st->vref_mv = voltage_uv / 1000;
508 st->use_internal_vref = !voltage_uv;
513 st->use_internal_vref = !voltage_uv;
522 st->use_internal_vref = !voltage_uv;
529 val = (voltage_uv | ref_bit_msk);
H A Dad5504.c277 int ret, voltage_uv = 0; local
292 voltage_uv = ret;
297 if (voltage_uv)
298 st->vref_mv = voltage_uv / 1000;
H A Dad5446.c230 int ret, voltage_uv = 0; local
242 voltage_uv = ret;
269 else if (voltage_uv)
270 st->vref_mv = voltage_uv / 1000;
/linux-master/drivers/iio/adc/
H A Dad7780.c112 int voltage_uv; local
118 voltage_uv = regulator_get_voltage(st->reg);
119 if (voltage_uv < 0)
120 return voltage_uv;
121 voltage_uv /= 1000;
122 *val = voltage_uv * st->gain;
124 st->int_vref_mv = voltage_uv;
H A Dad7791.c288 int voltage_uv; local
290 voltage_uv = regulator_get_voltage(st->reg);
291 if (voltage_uv < 0)
292 return voltage_uv;
294 *val = voltage_uv / 1000;
/linux-master/drivers/hwmon/
H A Dina3221.c444 int resistance_uo, current_ma, voltage_uv; local
460 voltage_uv = DIV_ROUND_CLOSEST(current_ma * resistance_uo, 1000);
463 voltage_uv = clamp_val(voltage_uv, -163800, 163800);
466 * Formula to convert voltage_uv to register value:
467 * regval = (voltage_uv / scale) << shift
477 regval = DIV_ROUND_CLOSEST(voltage_uv, 20) & 0xfffe;
479 regval = DIV_ROUND_CLOSEST(voltage_uv, 5) & 0xfff8;
/linux-master/drivers/net/wireless/ath/ath10k/
H A Dqmi_wlfw_v01.h518 u64 voltage_uv; member in struct:wlfw_vbatt_req_msg_v01
H A Dqmi_wlfw_v01.c1690 voltage_uv),
/linux-master/drivers/power/supply/
H A Dab8500_fg.c341 static u8 ab8500_volt_to_regval(int voltage_uv) argument
345 if (voltage_uv < ab8500_fg_lowbat_voltage_map[0])
349 if (voltage_uv < ab8500_fg_lowbat_voltage_map[i])
853 * @voltage_uv: The voltage to convert to a capacity in microvolt
857 static int ab8500_fg_volt_to_capacity(struct ab8500_fg *di, int voltage_uv) argument
862 return power_supply_batinfo_ocv2cap(bi, voltage_uv, di->bat_temp) * 10;
H A Dab8500_charger.c1011 static int ab8500_voltage_to_regval(int voltage_uv) argument
1016 if (voltage_uv < ab8500_charger_voltage_map[0])
1020 if (voltage_uv < ab8500_charger_voltage_map[i])
1026 if (voltage_uv == ab8500_charger_voltage_map[i])

Completed in 192 milliseconds