Home
last modified time | relevance | path

Searched refs:voltage (Results 1 – 25 of 190) sorted by relevance

12345678

/drivers/regulator/
DKconfig6 This framework is designed to provide a generic interface to voltage
8 provide voltage and current control to client or consumer drivers and
14 to both voltage regulators (where voltage output is controllable) and
32 tristate "Fixed voltage regulator support"
34 This driver provides support for fixed voltage regulators,
41 This driver provides a virtual consumer for the voltage and
61 This driver supports Marvell 88PM800 voltage regulator chips.
63 the voltage is programmed via I2C interface.
71 This driver supports 88PM8607 voltage regulator chips.
74 tristate "Active-semi act8865 voltage regulator"
[all …]
Dtwl-regulator.c710 int voltage = 0; in twl6030smps_list_voltage() local
714 voltage = 100000; in twl6030smps_list_voltage()
719 voltage = 0; in twl6030smps_list_voltage()
722 voltage = 1350 * 1000; in twl6030smps_list_voltage()
725 voltage = 1500 * 1000; in twl6030smps_list_voltage()
728 voltage = 1800 * 1000; in twl6030smps_list_voltage()
731 voltage = 1900 * 1000; in twl6030smps_list_voltage()
734 voltage = 2100 * 1000; in twl6030smps_list_voltage()
737 voltage += (600000 + (12500 * (index - 1))); in twl6030smps_list_voltage()
743 voltage = 0; in twl6030smps_list_voltage()
[all …]
Dpwm-regulator.c164 unsigned int voltage; in pwm_regulator_get_voltage() local
168 voltage = pwm_get_relative_duty_cycle(&pstate, duty_unit); in pwm_regulator_get_voltage()
176 voltage = min_uV_duty - voltage; in pwm_regulator_get_voltage()
179 voltage = voltage - min_uV_duty; in pwm_regulator_get_voltage()
183 voltage = DIV_ROUND_CLOSEST_ULL((u64)voltage * diff_uV, diff_duty); in pwm_regulator_get_voltage()
185 return voltage + min_uV; in pwm_regulator_get_voltage()
Dhelpers.c244 int ret, voltage; in regulator_map_voltage_linear() local
269 voltage = rdev->desc->ops->list_voltage(rdev, ret); in regulator_map_voltage_linear()
270 if (voltage < min_uV || voltage > max_uV) in regulator_map_voltage_linear()
292 int voltage, i; in regulator_map_voltage_linear_range() local
331 voltage = rdev->desc->ops->list_voltage(rdev, ret); in regulator_map_voltage_linear_range()
332 if (voltage < min_uV || voltage > max_uV) in regulator_map_voltage_linear_range()
/drivers/hwmon/
Dltc4245.c177 u32 voltage = 0; in ltc4245_get_voltage() local
182 voltage = regval * 55; in ltc4245_get_voltage()
186 voltage = regval * 22; in ltc4245_get_voltage()
190 voltage = regval * 15; in ltc4245_get_voltage()
194 voltage = regval * -55; in ltc4245_get_voltage()
197 voltage = regval * 10; in ltc4245_get_voltage()
205 return voltage; in ltc4245_get_voltage()
213 unsigned int voltage; in ltc4245_get_current() local
233 voltage = regval * 250; /* voltage in uV */ in ltc4245_get_current()
234 curr = voltage / 50; /* sense resistor 50 mOhm */ in ltc4245_get_current()
[all …]
Dltc4215.c83 u32 voltage = 0; in ltc4215_get_voltage() local
88 voltage = regval * 151 / 1000; in ltc4215_get_voltage()
92 voltage = regval * 605 / 10; in ltc4215_get_voltage()
99 voltage = regval * 482 * 125 / 1000; in ltc4215_get_voltage()
107 return voltage; in ltc4215_get_voltage()
131 const unsigned int voltage = data->regs[LTC4215_SENSE] * 151; in ltc4215_get_current() local
134 const unsigned int curr = voltage / 4; in ltc4215_get_current()
144 const int voltage = ltc4215_get_voltage(dev, attr->index); in ltc4215_show_voltage() local
146 return snprintf(buf, PAGE_SIZE, "%d\n", voltage); in ltc4215_show_voltage()
Dab8500.c82 int voltage, ret; in ab8500_read_sensor() local
90 voltage = ab8500_gpadc_convert(ab8500_data->gpadc, sensor); in ab8500_read_sensor()
91 if (voltage < 0) in ab8500_read_sensor()
92 return voltage; in ab8500_read_sensor()
94 ret = ab8500_voltage_to_temp(&ab8500_data->cfg, voltage, temp); in ab8500_read_sensor()
/drivers/power/supply/
Djz4740-battery.c45 long voltage; member
73 long voltage; in jz_battery_read_voltage() local
92 voltage = (long)val; in jz_battery_read_voltage()
94 voltage = t ? t : -ETIMEDOUT; in jz_battery_read_voltage()
102 return voltage; in jz_battery_read_voltage()
109 long voltage; in jz_battery_get_capacity() local
113 voltage = jz_battery_read_voltage(jz_battery); in jz_battery_get_capacity()
115 if (voltage < 0) in jz_battery_get_capacity()
116 return voltage; in jz_battery_get_capacity()
119 ret = ((voltage - info->voltage_min_design) * 100) / voltage_span; in jz_battery_get_capacity()
[all …]
Dtwl4030_madc_battery.c87 if (volt > calibration[0].voltage) { in twl4030_madc_bat_voltscale()
90 for (i = 0; calibration[i+1].voltage >= 0; i++) { in twl4030_madc_bat_voltscale()
91 if (volt <= calibration[i].voltage && in twl4030_madc_bat_voltscale()
92 volt >= calibration[i+1].voltage) { in twl4030_madc_bat_voltscale()
95 ((calibration[i].voltage - volt) * in twl4030_madc_bat_voltscale()
98 (calibration[i].voltage - in twl4030_madc_bat_voltscale()
99 calibration[i+1].voltage); in twl4030_madc_bat_voltscale()
188 return ((struct twl4030_madc_bat_calibration *)b)->voltage - in twl4030_cmp()
189 ((struct twl4030_madc_bat_calibration *)a)->voltage; in twl4030_cmp()
Drx51_battery.c57 int voltage = rx51_battery_read_adc(di->channel_vbat); in rx51_battery_read_voltage() local
59 if (voltage < 0) { in rx51_battery_read_voltage()
60 dev_err(di->dev, "Could not read ADC: %d\n", voltage); in rx51_battery_read_voltage()
61 return voltage; in rx51_battery_read_voltage()
64 return 1000 * (10000 * voltage / 1705); in rx51_battery_read_voltage()
/drivers/leds/
Dleds-regulator.c36 int voltage = regulator_list_voltage(supply, 0); in led_regulator_get_max_brightness() local
38 if (voltage <= 0) in led_regulator_get_max_brightness()
45 ret = regulator_set_voltage(supply, voltage, voltage); in led_regulator_get_max_brightness()
98 int voltage; in regulator_led_brightness_set() local
109 voltage = led_regulator_get_voltage(led->vcc, value); in regulator_led_brightness_set()
111 value, voltage); in regulator_led_brightness_set()
113 ret = regulator_set_voltage(led->vcc, voltage, voltage); in regulator_led_brightness_set()
116 voltage, ret); in regulator_led_brightness_set()
/drivers/thermal/
Ddevfreq_cooling.c218 unsigned long voltage; in get_static_power() local
230 voltage = dev_pm_opp_get_voltage(opp) / 1000; /* mV */ in get_static_power()
234 if (voltage == 0) { in get_static_power()
241 return dfc->power_ops->get_static_power(voltage); in get_static_power()
258 unsigned long voltage) in get_dynamic_power() argument
265 return dfc_power->get_dynamic_power(freq, voltage); in get_dynamic_power()
268 power = (u64)dfc_power->dyn_power_coeff * freq_mhz * voltage * voltage; in get_dynamic_power()
411 unsigned long power_dyn, voltage; in devfreq_cooling_gen_tables() local
423 voltage = dev_pm_opp_get_voltage(opp) / 1000; /* mV */ in devfreq_cooling_gen_tables()
428 power_dyn = get_dynamic_power(dfc, freq, voltage); in devfreq_cooling_gen_tables()
[all …]
/drivers/gpu/drm/nouveau/nvkm/subdev/clk/
Dgk20a.c370 .voltage = 0,
376 .voltage = 1,
382 .voltage = 2,
388 .voltage = 3,
394 .voltage = 4,
400 .voltage = 5,
406 .voltage = 6,
412 .voltage = 7,
418 .voltage = 8,
424 .voltage = 9,
[all …]
Dgm20b.c476 clk->new_uv = volt->vid[cstate->voltage].uv; in gm20b_clk_calc()
642 .voltage = 0,
648 .voltage = 1,
654 .voltage = 2,
660 .voltage = 3,
666 .voltage = 4,
672 .voltage = 5,
678 .voltage = 6,
684 .voltage = 7,
690 .voltage = 8,
[all …]
/drivers/media/usb/ttusb-dec/
Dttusbdecfe.c37 u8 voltage; member
144 lnb_voltage = htonl(state->voltage); in ttusbdecfe_dvbs_set_frontend()
184 enum fe_sec_voltage voltage) in ttusbdecfe_dvbs_set_voltage() argument
188 switch (voltage) { in ttusbdecfe_dvbs_set_voltage()
190 state->voltage = 13; in ttusbdecfe_dvbs_set_voltage()
193 state->voltage = 18; in ttusbdecfe_dvbs_set_voltage()
241 state->voltage = 0; in ttusbdecfe_dvbs_attach()
/drivers/gpu/drm/radeon/
Drs600.c221 struct radeon_voltage *voltage = &ps->clock_info[0].voltage; in rs600_pm_misc() local
225 if ((voltage->type == VOLTAGE_GPIO) && (voltage->gpio.valid)) { in rs600_pm_misc()
227 tmp = RREG32(voltage->gpio.reg); in rs600_pm_misc()
228 if (voltage->active_high) in rs600_pm_misc()
229 tmp |= voltage->gpio.mask; in rs600_pm_misc()
231 tmp &= ~(voltage->gpio.mask); in rs600_pm_misc()
232 WREG32(voltage->gpio.reg, tmp); in rs600_pm_misc()
233 if (voltage->delay) in rs600_pm_misc()
234 udelay(voltage->delay); in rs600_pm_misc()
236 tmp = RREG32(voltage->gpio.reg); in rs600_pm_misc()
[all …]
/drivers/input/keyboard/
Dsun4i-lradc-keys.c67 u32 voltage; member
85 u32 i, ints, val, voltage, diff, keycode = 0, closest = 0xffffffff; in sun4i_lradc_irq() local
101 voltage = val * lradc->vref / 63; in sun4i_lradc_irq()
104 diff = abs(lradc->chan0_map[i].voltage - voltage); in sun4i_lradc_irq()
192 error = of_property_read_u32(pp, "voltage", &map->voltage); in sun4i_lradc_load_dt_keymap()
Dadc-keys.c24 u32 voltage; member
49 diff = abs(st->map[i].voltage - value); in adc_keys_poll()
89 &map[i].voltage)) { in adc_keys_load_keymap()
94 map[i].voltage /= 1000; in adc_keys_load_keymap()
/drivers/mfd/
Drts5249.c36 static void rts5249_fill_driving(struct rtsx_pcr *pcr, u8 voltage) in rts5249_fill_driving() argument
52 if (voltage == OUTPUT_3V3) { in rts5249_fill_driving()
250 static int rtsx_base_switch_output_voltage(struct rtsx_pcr *pcr, u8 voltage) in rtsx_base_switch_output_voltage() argument
255 switch (voltage) { in rtsx_base_switch_output_voltage()
278 pcr_dbg(pcr, "unknown output voltage %d\n", voltage); in rtsx_base_switch_output_voltage()
284 rts5249_fill_driving(pcr, voltage); in rtsx_base_switch_output_voltage()
493 static int rts525a_switch_output_voltage(struct rtsx_pcr *pcr, u8 voltage) in rts525a_switch_output_voltage() argument
495 switch (voltage) { in rts525a_switch_output_voltage()
512 rts5249_fill_driving(pcr, voltage); in rts525a_switch_output_voltage()
Drts5227.c37 static void rts5227_fill_driving(struct rtsx_pcr *pcr, u8 voltage) in rts5227_fill_driving() argument
53 if (voltage == OUTPUT_3V3) { in rts5227_fill_driving()
204 static int rts5227_switch_output_voltage(struct rtsx_pcr *pcr, u8 voltage) in rts5227_switch_output_voltage() argument
208 if (voltage == OUTPUT_3V3) { in rts5227_switch_output_voltage()
212 } else if (voltage == OUTPUT_1V8) { in rts5227_switch_output_voltage()
225 rts5227_fill_driving(pcr, voltage); in rts5227_switch_output_voltage()
Drtl8411.c194 static int rtl8411_do_switch_output_voltage(struct rtsx_pcr *pcr, u8 voltage, in rtl8411_do_switch_output_voltage() argument
201 if (voltage == OUTPUT_3V3) { in rtl8411_do_switch_output_voltage()
207 } else if (voltage == OUTPUT_1V8) { in rtl8411_do_switch_output_voltage()
220 static int rtl8411_switch_output_voltage(struct rtsx_pcr *pcr, u8 voltage) in rtl8411_switch_output_voltage() argument
222 return rtl8411_do_switch_output_voltage(pcr, voltage, in rtl8411_switch_output_voltage()
226 static int rtl8402_switch_output_voltage(struct rtsx_pcr *pcr, u8 voltage) in rtl8402_switch_output_voltage() argument
228 return rtl8411_do_switch_output_voltage(pcr, voltage, in rtl8402_switch_output_voltage()
/drivers/media/pci/mantis/
Dmantis_vp1034.c47 int vp1034_set_voltage(struct dvb_frontend *fe, enum fe_sec_voltage voltage) in vp1034_set_voltage() argument
51 switch (voltage) { in vp1034_set_voltage()
66 dprintk(MANTIS_ERROR, 1, "Invalid = (%d)", (u32) voltage); in vp1034_set_voltage()
/drivers/power/avs/
DKconfig5 operating voltage of a device in order to optimize (i.e. reduce)
7 At a given operating point the voltage is adapted depending on
20 voltage supplied by the regulators.
/drivers/media/usb/dvb-usb/
Dvp702x-fe.c29 enum fe_sec_voltage voltage; member
172 if (st->voltage == SEC_VOLTAGE_18) in vp702x_fe_set_frontend()
289 enum fe_sec_voltage voltage) in vp702x_fe_set_voltage() argument
296 st->voltage = voltage; in vp702x_fe_set_voltage()
298 if (voltage != SEC_VOLTAGE_OFF) in vp702x_fe_set_voltage()
/drivers/gpu/drm/nouveau/nvkm/subdev/bios/
Dperf.c109 info->voltage = nvbios_rd08(bios, perf + 0x38); in nvbios_perfEp()
115 info->voltage = nvbios_rd08(bios, perf + 0x05); in nvbios_perfEp()
131 info->voltage = nvbios_rd08(bios, perf + 0x05); in nvbios_perfEp()
140 info->voltage = nvbios_rd08(bios, perf + 0x07); in nvbios_perfEp()
148 info->voltage = nvbios_rd08(bios, perf + 0x02); in nvbios_perfEp()

12345678