Home
last modified time | relevance | path

Searched refs:scale_avail (Results 1 – 8 of 8) sorted by relevance

/Linux-v5.4/drivers/iio/dac/
Dad5592r-base.c328 if (val == st->scale_avail[0][0] && in ad5592r_write_raw()
329 val2 == st->scale_avail[0][1]) in ad5592r_write_raw()
331 else if (val == st->scale_avail[1][0] && in ad5592r_write_raw()
332 val2 == st->scale_avail[1][1]) in ad5592r_write_raw()
486 st->scale_avail[0][0], st->scale_avail[0][1], in ad5592r_show_scale_available()
487 st->scale_avail[1][0], st->scale_avail[1][1]); in ad5592r_show_scale_available()
589 st->scale_avail[0][0] = in ad5592r_init_scales()
590 div_s64_rem(tmp, 1000000000LL, &st->scale_avail[0][1]); in ad5592r_init_scales()
591 st->scale_avail[1][0] = in ad5592r_init_scales()
592 div_s64_rem(tmp * 2, 1000000000LL, &st->scale_avail[1][1]); in ad5592r_init_scales()
Dad5592r-base.h57 int scale_avail[2][2]; member
/Linux-v5.4/drivers/iio/adc/
Dmxs-lradc-adc.c124 struct mxs_lradc_scale scale_avail[LRADC_MAX_TOTAL_CHANS][2]; member
273 struct mxs_lradc_scale *scale_avail = in mxs_lradc_adc_write_raw() local
274 adc->scale_avail[chan->channel]; in mxs_lradc_adc_write_raw()
284 if (val == scale_avail[MXS_LRADC_DIV_DISABLED].integer && in mxs_lradc_adc_write_raw()
285 val2 == scale_avail[MXS_LRADC_DIV_DISABLED].nano) { in mxs_lradc_adc_write_raw()
289 } else if (val == scale_avail[MXS_LRADC_DIV_ENABLED].integer && in mxs_lradc_adc_write_raw()
290 val2 == scale_avail[MXS_LRADC_DIV_ENABLED].nano) { in mxs_lradc_adc_write_raw()
324 for (i = 0; i < ARRAY_SIZE(adc->scale_avail[ch]); i++) in mxs_lradc_adc_show_scale_avail()
326 adc->scale_avail[ch][i].integer, in mxs_lradc_adc_show_scale_avail()
327 adc->scale_avail[ch][i].nano); in mxs_lradc_adc_show_scale_avail()
[all …]
Dad7793.c159 u32 scale_avail[8][2]; member
328 for (i = 0; i < ARRAY_SIZE(st->scale_avail); i++) { in ad7793_setup()
334 st->scale_avail[i][1] = do_div(scale_uv, 100000000) * 10; in ad7793_setup()
335 st->scale_avail[i][0] = scale_uv; in ad7793_setup()
363 for (i = 0; i < ARRAY_SIZE(st->scale_avail); i++) in ad7793_show_scale_available()
364 len += sprintf(buf + len, "%d.%09u ", st->scale_avail[i][0], in ad7793_show_scale_available()
365 st->scale_avail[i][1]); in ad7793_show_scale_available()
419 scale_avail[(st->conf >> 8) & 0x7][0]; in ad7793_read_raw()
421 scale_avail[(st->conf >> 8) & 0x7][1]; in ad7793_read_raw()
481 for (i = 0; i < ARRAY_SIZE(st->scale_avail); i++) in ad7793_write_raw()
[all …]
Dnau7802.c59 u32 scale_avail[8]; member
87 for (i = 0; i < ARRAY_SIZE(st->scale_avail); i++) in nau7802_show_scales()
89 st->scale_avail[i]); in nau7802_show_scales()
368 for (i = 0; i < ARRAY_SIZE(st->scale_avail); i++) in nau7802_write_raw()
369 if (val2 == st->scale_avail[i]) in nau7802_write_raw()
488 for (i = 0; i < ARRAY_SIZE(st->scale_avail); i++) in nau7802_probe()
489 st->scale_avail[i] = (((u64)st->vref_mv) * 1000000000ULL) in nau7802_probe()
Dad7606.c191 *val2 = st->scale_avail[st->range[ch]]; in ad7606_read_raw()
222 return ad7606_show_avail(buf, st->scale_avail, st->num_scales, true); in in_voltage_scale_available_show()
265 i = find_closest(val2, st->scale_avail, st->num_scales); in ad7606_write_raw()
589 st->scale_avail = ad7606_scale_avail; in ad7606_probe()
655 st->scale_avail = ad7616_sw_scale_avail; in ad7606_probe()
Dad7606.h101 const unsigned int *scale_avail; member
/Linux-v5.4/drivers/staging/iio/adc/
Dad7192.c167 u32 scale_avail[8][2]; member
326 for (i = 0; i < ARRAY_SIZE(st->scale_avail); i++) { in ad7192_setup()
332 st->scale_avail[i][1] = do_div(scale_uv, 100000000) * 10; in ad7192_setup()
333 st->scale_avail[i][0] = scale_uv; in ad7192_setup()
566 *val = st->scale_avail[AD7192_CONF_GAIN(st->conf)][0]; in ad7192_read_raw()
567 *val2 = st->scale_avail[AD7192_CONF_GAIN(st->conf)][1]; in ad7192_read_raw()
617 for (i = 0; i < ARRAY_SIZE(st->scale_avail); i++) in ad7192_write_raw()
618 if (val2 == st->scale_avail[i][1]) { in ad7192_write_raw()
685 *vals = (int *)st->scale_avail; in ad7192_read_avail()
688 *length = ARRAY_SIZE(st->scale_avail) * 2; in ad7192_read_avail()