| /Linux-v5.15/drivers/iio/adc/ |
| D | fsl-imx25-gcq.c | 41 struct regulator *vref[4]; member 202 priv->vref[MX25_ADC_REFP_INT] = NULL; in mx25_gcq_setup_cfgs() 203 priv->vref[MX25_ADC_REFP_EXT] = in mx25_gcq_setup_cfgs() 205 priv->vref[MX25_ADC_REFP_XP] = in mx25_gcq_setup_cfgs() 207 priv->vref[MX25_ADC_REFP_YP] = in mx25_gcq_setup_cfgs() 236 if (IS_ERR(priv->vref[refp])) { in mx25_gcq_setup_cfgs() 240 return PTR_ERR(priv->vref[refp]); in mx25_gcq_setup_cfgs() 243 regulator_get_voltage(priv->vref[refp]); in mx25_gcq_setup_cfgs() 291 if (!IS_ERR_OR_NULL(priv->vref[i])) in mx25_gcq_setup_cfgs() 292 devm_regulator_put(priv->vref[i]); in mx25_gcq_setup_cfgs() [all …]
|
| D | mcp3911.c | 52 struct regulator *vref; member 127 if (adc->vref) { in mcp3911_read_raw() 128 ret = regulator_get_voltage(adc->vref); in mcp3911_read_raw() 221 if (adc->vref) { in mcp3911_config() 255 adc->vref = devm_regulator_get_optional(&adc->spi->dev, "vref"); in mcp3911_probe() 256 if (IS_ERR(adc->vref)) { in mcp3911_probe() 257 if (PTR_ERR(adc->vref) == -ENODEV) { in mcp3911_probe() 258 adc->vref = NULL; in mcp3911_probe() 262 PTR_ERR(adc->vref)); in mcp3911_probe() 263 return PTR_ERR(adc->vref); in mcp3911_probe() [all …]
|
| D | rcar-gyroadc.c | 68 struct regulator *vref[8]; member 181 unsigned int vref; in rcar_gyroadc_read_raw() local 189 consumer = priv->vref[0]; in rcar_gyroadc_read_raw() 191 consumer = priv->vref[chan->channel]; in rcar_gyroadc_read_raw() 226 vref = regulator_get_voltage(consumer); in rcar_gyroadc_read_raw() 227 *val = vref / 1000; in rcar_gyroadc_read_raw() 322 struct regulator *vref; in rcar_gyroadc_parse_subdevs() local 394 vref = devm_regulator_get(dev, "vref"); in rcar_gyroadc_parse_subdevs() 396 if (IS_ERR(vref)) { in rcar_gyroadc_parse_subdevs() 399 ret = PTR_ERR(vref); in rcar_gyroadc_parse_subdevs() [all …]
|
| D | npcm_adc.c | 26 struct regulator *vref; member 156 if (!IS_ERR(info->vref)) { in npcm_adc_read_raw() 157 vref_uv = regulator_get_voltage(info->vref); in npcm_adc_read_raw() 237 info->vref = devm_regulator_get_optional(&pdev->dev, "vref"); in npcm_adc_probe() 238 if (!IS_ERR(info->vref)) { in npcm_adc_probe() 239 ret = regulator_enable(info->vref); in npcm_adc_probe() 252 if (PTR_ERR(info->vref) != -ENODEV) { in npcm_adc_probe() 253 ret = PTR_ERR(info->vref); in npcm_adc_probe() 292 if (!IS_ERR(info->vref)) in npcm_adc_probe() 293 regulator_disable(info->vref); in npcm_adc_probe() [all …]
|
| D | lpc18xx_adc.c | 43 struct regulator *vref; member 105 *val = regulator_get_voltage(adc->vref) / 1000; in lpc18xx_adc_read_raw() 148 adc->vref = devm_regulator_get(&pdev->dev, "vref"); in lpc18xx_adc_probe() 149 if (IS_ERR(adc->vref)) { in lpc18xx_adc_probe() 151 return PTR_ERR(adc->vref); in lpc18xx_adc_probe() 160 ret = regulator_enable(adc->vref); in lpc18xx_adc_probe() 188 regulator_disable(adc->vref); in lpc18xx_adc_probe() 201 regulator_disable(adc->vref); in lpc18xx_adc_remove()
|
| D | ad7091r-base.c | 46 struct regulator *vref; member 147 if (st->vref) { in ad7091r_read_raw() 148 ret = regulator_get_voltage(st->vref); in ad7091r_read_raw() 207 regulator_disable(st->vref); in ad7091r_remove() 242 st->vref = devm_regulator_get_optional(dev, "vref"); in ad7091r_probe() 243 if (IS_ERR(st->vref)) { in ad7091r_probe() 244 if (PTR_ERR(st->vref) == -EPROBE_DEFER) in ad7091r_probe() 246 st->vref = NULL; in ad7091r_probe() 248 ret = regulator_enable(st->vref); in ad7091r_probe()
|
| D | max1241.c | 26 struct regulator *vref; member 95 vref_uV = regulator_get_voltage(adc->vref); in max1241_read_raw() 130 err = regulator_disable(adc->vref); in max1241_disable_vref_action() 166 adc->vref = devm_regulator_get(dev, "vref"); in max1241_probe() 167 if (IS_ERR(adc->vref)) { in max1241_probe() 169 return PTR_ERR(adc->vref); in max1241_probe() 172 ret = regulator_enable(adc->vref); in max1241_probe()
|
| D | ad7949.c | 51 struct regulator *vref; member 181 ret = regulator_get_voltage(ad7949_adc->vref); in ad7949_spi_read_raw() 260 ad7949_adc->vref = devm_regulator_get(dev, "vref"); in ad7949_spi_probe() 261 if (IS_ERR(ad7949_adc->vref)) { in ad7949_spi_probe() 263 return PTR_ERR(ad7949_adc->vref); in ad7949_spi_probe() 266 ret = regulator_enable(ad7949_adc->vref); in ad7949_spi_probe() 290 regulator_disable(ad7949_adc->vref); in ad7949_spi_probe() 302 regulator_disable(ad7949_adc->vref); in ad7949_spi_remove()
|
| D | rockchip_saradc.c | 51 struct regulator *vref; member 254 regulator_disable(info->vref); in rockchip_saradc_regulator_disable() 314 regulator_unregister_notifier(info->vref, &info->nb); in rockchip_saradc_regulator_unreg_notifier() 396 info->vref = devm_regulator_get(&pdev->dev, "vref"); in rockchip_saradc_probe() 397 if (IS_ERR(info->vref)) { in rockchip_saradc_probe() 399 PTR_ERR(info->vref)); in rockchip_saradc_probe() 400 return PTR_ERR(info->vref); in rockchip_saradc_probe() 416 ret = regulator_enable(info->vref); in rockchip_saradc_probe() 429 ret = regulator_get_voltage(info->vref); in rockchip_saradc_probe() 476 ret = regulator_register_notifier(info->vref, &info->nb); in rockchip_saradc_probe() [all …]
|
| D | ti-tlc4541.c | 112 int vref; in tlc4541_get_range() local 114 vref = regulator_get_voltage(st->reg); in tlc4541_get_range() 115 if (vref < 0) in tlc4541_get_range() 116 return vref; in tlc4541_get_range() 118 vref /= 1000; in tlc4541_get_range() 120 return vref; in tlc4541_get_range()
|
| D | ad7923.c | 236 int vref; in ad7923_get_range() local 238 vref = regulator_get_voltage(st->reg); in ad7923_get_range() 239 if (vref < 0) in ad7923_get_range() 240 return vref; in ad7923_get_range() 242 vref /= 1000; in ad7923_get_range() 245 vref *= 2; in ad7923_get_range() 247 return vref; in ad7923_get_range()
|
| D | ad7124.c | 169 struct regulator *vref[4]; member 365 if (IS_ERR(st->vref[refsel])) { in ad7124_init_config_vref() 369 return PTR_ERR(st->vref[refsel]); in ad7124_init_config_vref() 371 cfg->vref_mv = regulator_get_voltage(st->vref[refsel]); in ad7124_init_config_vref() 589 unsigned int res, gain, full_scale, vref; in ad7124_write_raw() local 614 vref = st->channels[chan->address].cfg.vref_mv * 1000000LL; in ad7124_write_raw() 615 res = DIV_ROUND_CLOSEST(vref, full_scale); in ad7124_write_raw() 899 for (i = 0; i < ARRAY_SIZE(st->vref); i++) { in ad7124_probe() 903 st->vref[i] = devm_regulator_get_optional(&spi->dev, in ad7124_probe() 905 if (PTR_ERR(st->vref[i]) == -ENODEV) in ad7124_probe() [all …]
|
| D | imx7d_adc.c | 116 struct regulator *vref; member 318 info->vref_uv = regulator_get_voltage(info->vref); in imx7d_adc_read_raw() 434 ret = regulator_enable(info->vref); in imx7d_adc_enable() 446 regulator_disable(info->vref); in imx7d_adc_enable() 463 regulator_disable(info->vref); in imx7d_adc_disable() 505 info->vref = devm_regulator_get(dev, "vref"); in imx7d_adc_probe() 506 if (IS_ERR(info->vref)) { in imx7d_adc_probe() 507 ret = PTR_ERR(info->vref); in imx7d_adc_probe()
|
| D | lpc32xx_adc.c | 51 struct regulator *vref; member 88 *val = regulator_get_voltage(st->vref) / 1000; in lpc32xx_read_raw() 186 st->vref = devm_regulator_get(&pdev->dev, "vref"); in lpc32xx_adc_probe() 187 if (IS_ERR(st->vref)) { in lpc32xx_adc_probe()
|
| D | vf610_adc.c | 162 struct regulator *vref; member 839 info->vref = devm_regulator_get(&pdev->dev, "vref"); in vf610_adc_probe() 840 if (IS_ERR(info->vref)) in vf610_adc_probe() 841 return PTR_ERR(info->vref); in vf610_adc_probe() 843 ret = regulator_enable(info->vref); in vf610_adc_probe() 847 info->vref_uv = regulator_get_voltage(info->vref); in vf610_adc_probe() 897 regulator_disable(info->vref); in vf610_adc_probe() 909 regulator_disable(info->vref); in vf610_adc_remove() 928 regulator_disable(info->vref); in vf610_adc_suspend() 939 ret = regulator_enable(info->vref); in vf610_adc_resume() [all …]
|
| D | ad799x.c | 127 struct regulator *vref; member 302 ret = regulator_get_voltage(st->vref); in ad799x_read_raw() 800 st->vref = devm_regulator_get(&client->dev, "vref"); in ad799x_probe() 801 if (IS_ERR(st->vref)) { in ad799x_probe() 802 ret = PTR_ERR(st->vref); in ad799x_probe() 805 ret = regulator_enable(st->vref); in ad799x_probe() 848 regulator_disable(st->vref); in ad799x_probe() 863 regulator_disable(st->vref); in ad799x_remove() 875 regulator_disable(st->vref); in ad799x_suspend() 892 ret = regulator_enable(st->vref); in ad799x_resume() [all …]
|
| /Linux-v5.15/drivers/iio/dac/ |
| D | dpot-dac.c | 38 struct regulator *vref; member 70 tmp *= regulator_get_voltage(dac->vref) / 1000; in dpot_dac_read_raw() 84 *val *= regulator_get_voltage(dac->vref) / 1000; in dpot_dac_read_raw() 186 dac->vref = devm_regulator_get(dev, "vref"); in dpot_dac_probe() 187 if (IS_ERR(dac->vref)) in dpot_dac_probe() 188 return dev_err_probe(&pdev->dev, PTR_ERR(dac->vref), in dpot_dac_probe() 210 ret = regulator_enable(dac->vref); in dpot_dac_probe() 225 regulator_disable(dac->vref); in dpot_dac_probe() 235 regulator_disable(dac->vref); in dpot_dac_remove()
|
| D | lpc18xx_dac.c | 34 struct regulator *vref; member 65 *val = regulator_get_voltage(dac->vref) / 1000; in lpc18xx_dac_read_raw() 129 dac->vref = devm_regulator_get(&pdev->dev, "vref"); in lpc18xx_dac_probe() 130 if (IS_ERR(dac->vref)) { in lpc18xx_dac_probe() 132 return PTR_ERR(dac->vref); in lpc18xx_dac_probe() 141 ret = regulator_enable(dac->vref); in lpc18xx_dac_probe() 167 regulator_disable(dac->vref); in lpc18xx_dac_probe() 180 regulator_disable(dac->vref); in lpc18xx_dac_remove()
|
| D | stm32-dac-core.c | 28 struct regulator *vref; member 58 ret = regulator_enable(priv->vref); in stm32_dac_core_hw_start() 73 regulator_disable(priv->vref); in stm32_dac_core_hw_start() 84 regulator_disable(priv->vref); in stm32_dac_core_hw_stop() 127 priv->vref = devm_regulator_get(dev, "vref"); in stm32_dac_probe() 128 if (IS_ERR(priv->vref)) { in stm32_dac_probe() 129 ret = PTR_ERR(priv->vref); in stm32_dac_probe() 142 ret = regulator_get_voltage(priv->vref); in stm32_dac_probe()
|
| D | ti-dac7311.c | 49 struct regulator *vref; member 179 ret = regulator_get_voltage(ti_dac->vref); in ti_dac_read_raw() 268 ti_dac->vref = devm_regulator_get(dev, "vref"); in ti_dac_probe() 269 if (IS_ERR(ti_dac->vref)) { in ti_dac_probe() 271 return PTR_ERR(ti_dac->vref); in ti_dac_probe() 274 ret = regulator_enable(ti_dac->vref); in ti_dac_probe() 292 regulator_disable(ti_dac->vref); in ti_dac_probe() 303 regulator_disable(ti_dac->vref); in ti_dac_remove()
|
| D | ti-dac082s085.c | 51 struct regulator *vref; member 200 ret = regulator_get_voltage(ti_dac->vref); in ti_dac_read_raw() 288 ti_dac->vref = devm_regulator_get(dev, "vref"); in ti_dac_probe() 289 if (IS_ERR(ti_dac->vref)) in ti_dac_probe() 290 return PTR_ERR(ti_dac->vref); in ti_dac_probe() 292 ret = regulator_enable(ti_dac->vref); in ti_dac_probe() 312 regulator_disable(ti_dac->vref); in ti_dac_probe() 323 regulator_disable(ti_dac->vref); in ti_dac_remove()
|
| D | ti-dac5571.c | 47 struct regulator *vref; member 251 ret = regulator_get_voltage(data->vref); in dac5571_read_raw() 333 data->vref = devm_regulator_get(dev, "vref"); in dac5571_probe() 334 if (IS_ERR(data->vref)) in dac5571_probe() 335 return PTR_ERR(data->vref); in dac5571_probe() 337 ret = regulator_enable(data->vref); in dac5571_probe() 372 regulator_disable(data->vref); in dac5571_probe() 382 regulator_disable(data->vref); in dac5571_remove()
|
| /Linux-v5.15/drivers/hwmon/ |
| D | adc128d818.c | 62 int vref; /* Reference voltage in mV */ member 158 val = DIV_ROUND_CLOSEST(data->in[index][nr] * data->vref, 4095); in adc128_in_show() 436 int err, vref; in adc128_probe() local 449 vref = regulator_get_voltage(regulator); in adc128_probe() 450 if (vref < 0) { in adc128_probe() 451 err = vref; in adc128_probe() 454 data->vref = DIV_ROUND_CLOSEST(vref, 1000); in adc128_probe() 456 data->vref = 2560; /* 2.56V, in mV */ in adc128_probe()
|
| /Linux-v5.15/arch/arm64/boot/dts/freescale/ |
| D | imx8mq-nitrogen.dts | 61 reg_vref_0v9: regulator-vref-0v9 { 63 regulator-name = "vref-0v9"; 68 reg_vref_1v8: regulator-vref-1v8 { 70 regulator-name = "vref-1v8"; 75 reg_vref_2v5: regulator-vref-2v5 { 77 regulator-name = "vref-2v5"; 82 reg_vref_3v3: regulator-vref-3v3 { 84 regulator-name = "vref-3v3"; 89 reg_vref_5v: regulator-vref-5v { 91 regulator-name = "vref-5v";
|
| /Linux-v5.15/Documentation/devicetree/bindings/input/touchscreen/ |
| D | ads7846.txt | 28 ti,vref-delay-usecs vref supply delay in usecs, 0 for 29 external vref (u16). 30 ti,vref-mv The VREF voltage, in millivolts (u16). 33 ti,keep-vref-on set to keep vref on for differential
|