/Linux-v5.4/drivers/hwmon/ |
D | ads7828.c | 109 unsigned int vref_mv = ADS7828_INT_VREF_MV; in ads7828_probe() local 124 if (ext_vref && pdata->vref_mv) in ads7828_probe() 125 vref_mv = pdata->vref_mv; in ads7828_probe() 132 vref_mv = DIV_ROUND_CLOSEST(vref_uv, 1000); in ads7828_probe() 133 if (vref_mv < ADS7828_EXT_VREF_MV_MIN || in ads7828_probe() 134 vref_mv > ADS7828_EXT_VREF_MV_MAX) in ads7828_probe() 147 vref_mv = clamp_val(vref_mv, ADS7828_EXT_VREF_MV_MIN, in ads7828_probe() 152 data->lsb_resol = DIV_ROUND_CLOSEST(vref_mv * 1000, 4096); in ads7828_probe() 156 data->lsb_resol = DIV_ROUND_CLOSEST(vref_mv * 1000, 256); in ads7828_probe()
|
/Linux-v5.4/drivers/iio/dac/ |
D | ltc2632.c | 36 const int vref_mv; member 49 int vref_mv; member 93 *val = st->vref_mv; in ltc2632_read_raw() 206 .vref_mv = 2500, 210 .vref_mv = 2500, 214 .vref_mv = 2500, 218 .vref_mv = 4096, 222 .vref_mv = 4096, 226 .vref_mv = 4096, 253 st->vref_mv = chip_info->vref_mv; in ltc2632_probe() [all …]
|
D | max517.c | 35 unsigned short vref_mv[8]; member 77 *val = data->vref_mv[chan->channel]; in max517_read_raw() 187 data->vref_mv[chan] = 5000; /* mV */ in max517_probe() 189 data->vref_mv[chan] = platform_data->vref_mv[chan]; in max517_probe()
|
D | ad5791.c | 87 unsigned short vref_mv; member 267 *val = st->vref_mv; in ad5791_read_raw() 272 do_div(val64, st->vref_mv); in ad5791_read_raw() 385 st->vref_mv = (pos_voltage_uv + neg_voltage_uv) / 1000; in ad5791_probe() 388 st->vref_mv = pdata->vref_pos_mv + pdata->vref_neg_mv; in ad5791_probe() 402 st->ctrl = AD5761_CTRL_LINCOMP(st->chip_info->get_lin_comp(st->vref_mv)) in ad5791_probe()
|
D | ad5504.c | 53 unsigned short vref_mv; member 113 *val = st->vref_mv; in ad5504_read_raw() 299 st->vref_mv = voltage_uv / 1000; in ad5504_probe() 301 st->vref_mv = pdata->vref_mv; in ad5504_probe()
|
D | mcp4922.c | 30 unsigned int vref_mv; member 72 *val = state->vref_mv; in mcp4922_read_raw() 151 state->vref_mv = ret / 1000; in mcp4922_probe()
|
D | ad5624r_spi.c | 55 *val = st->vref_mv; in ad5624r_read_raw() 250 st->vref_mv = voltage_uv / 1000; in ad5624r_probe() 252 st->vref_mv = st->chip_info->int_vref_mv; in ad5624r_probe()
|
D | stm32-dac-core.c | 100 priv->common.vref_mv = ret / 1000; in stm32_dac_probe() 101 dev_dbg(dev, "vref+=%dmV\n", priv->common.vref_mv); in stm32_dac_probe()
|
D | stm32-dac-core.h | 34 int vref_mv; member
|
D | ad5446.c | 40 unsigned short vref_mv; member 176 *val = st->vref_mv; in ad5446_read_raw() 260 st->vref_mv = st->chip_info->int_vref_mv; in ad5446_probe() 262 st->vref_mv = voltage_uv / 1000; in ad5446_probe()
|
D | max5821.c | 36 unsigned short vref_mv; member 247 *val = data->vref_mv; in max5821_read_raw() 341 data->vref_mv = ret / 1000; in max5821_probe()
|
D | ad5624r.h | 58 unsigned short vref_mv; member
|
D | ad5686.c | 139 *val = st->vref_mv; in ad5686_read_raw() 456 st->vref_mv = voltage_uv / 1000; in ad5686_probe() 458 st->vref_mv = st->chip_info->int_vref_mv; in ad5686_probe()
|
D | ad5686.h | 127 unsigned short vref_mv; member
|
/Linux-v5.4/drivers/iio/adc/ |
D | ti-ads8688.c | 69 unsigned int vref_mv; member 124 ads8688_range_def[0].scale * st->vref_mv, in ads8688_show_scales() 125 ads8688_range_def[1].scale * st->vref_mv, in ads8688_show_scales() 126 ads8688_range_def[2].scale * st->vref_mv); in ads8688_show_scales() 262 scale_mv = st->vref_mv; in ads8688_read_raw() 305 if (offset == 0 && val2 == ads8688_range_def[0].scale * st->vref_mv) { in ads8688_write_raw() 312 if (val2 == ads8688_range_def[i].scale * st->vref_mv && in ads8688_write_raw() 437 st->vref_mv = ret / 1000; in ads8688_probe() 440 st->vref_mv = ADS8688_VREF_MV; in ads8688_probe()
|
D | ad7793.c | 256 unsigned int vref_mv) in ad7793_setup() argument 329 scale_uv = ((u64)vref_mv * 100000000) in ad7793_setup() 709 int ret, vref_mv = 0; in ad7793_probe() local 738 vref_mv = regulator_get_voltage(st->reg); in ad7793_probe() 739 if (vref_mv < 0) { in ad7793_probe() 740 ret = vref_mv; in ad7793_probe() 744 vref_mv /= 1000; in ad7793_probe() 746 vref_mv = 1170; /* Build-in ref */ in ad7793_probe() 766 ret = ad7793_setup(indio_dev, pdata, vref_mv); in ad7793_probe()
|
D | ad7124.c | 116 unsigned int vref_mv; member 304 *val = st->channel_config[chan->address].vref_mv; in ad7124_read_raw() 349 vref = st->channel_config[chan->address].vref_mv * 1000000LL; in ad7124_write_raw() 420 st->channel_config[channel_number].vref_mv = in ad7124_init_channel_vref() 423 st->channel_config[channel_number].vref_mv /= 1000; in ad7124_init_channel_vref() 426 st->channel_config[channel_number].vref_mv = 2500; in ad7124_init_channel_vref()
|
D | nau7802.c | 55 u32 vref_mv; member 342 *val = st->vref_mv; in nau7802_read_raw() 465 st->vref_mv = tmp; in nau7802_probe() 489 st->scale_avail[i] = (((u64)st->vref_mv) * 1000000000ULL) in nau7802_probe()
|
D | ad7266.c | 29 unsigned long vref_mv; member 168 scale_mv = st->vref_mv; in ad7266_read_raw() 406 st->vref_mv = ret / 1000; in ad7266_probe() 412 st->vref_mv = 2500; in ad7266_probe()
|
D | ti-ads7950.c | 78 unsigned int vref_mv; member 351 if (st->vref_mv) { in ti_ads7950_get_range() 352 vref = st->vref_mv; in ti_ads7950_get_range() 599 st->vref_mv = TI_ADS7950_VA_MV_ACPI_DEFAULT; in ti_ads7950_probe()
|
/Linux-v5.4/include/linux/iio/dac/ |
D | ad5504.h | 12 u16 vref_mv; member
|
D | max517.h | 11 u16 vref_mv[8]; member
|
/Linux-v5.4/include/linux/platform_data/ |
D | ads7828.h | 23 unsigned int vref_mv; member
|
/Linux-v5.4/include/linux/spi/ |
D | ads7846.h | 18 u16 vref_mv; /* external vref value, milliVolts member
|
/Linux-v5.4/drivers/input/touchscreen/ |
D | ads7846.c | 106 u16 vref_mv; member 460 retval *= ts->vref_mv; in SHOW() 513 if (!ts->vref_mv) { in ads784x_hwmon_register() 515 ts->vref_mv = 2500; in ads784x_hwmon_register() 521 if (!ts->vref_mv) { in ads784x_hwmon_register() 1208 of_property_read_u16(node, "ti,vref-mv", &pdata->vref_mv); in ads7846_probe_dt() 1320 ts->vref_mv = pdata->vref_mv; in ads7846_probe()
|