Searched refs:scales (Results 1 - 4 of 4) sorted by relevance
/kernel/linux/linux-5.10/drivers/iio/adc/ |
H A D | ad9467.c | 122 unsigned int (*scales)[2]; member 380 *vals = (const int *)st->scales; in ad9467_read_avail() 408 st->scales = devm_kmalloc_array(&st->spi->dev, info->num_scales, in ad9467_scale_fill() 409 sizeof(*st->scales), GFP_KERNEL); in ad9467_scale_fill() 410 if (!st->scales) in ad9467_scale_fill() 415 st->scales[i][0] = val1; in ad9467_scale_fill() 416 st->scales[i][1] = val2; in ad9467_scale_fill()
|
/kernel/linux/linux-6.6/drivers/iio/adc/ |
H A D | ad9467.c | 123 unsigned int (*scales)[2]; member 385 *vals = (const int *)st->scales; in ad9467_read_avail() 413 st->scales = devm_kmalloc_array(&st->spi->dev, info->num_scales, in ad9467_scale_fill() 414 sizeof(*st->scales), GFP_KERNEL); in ad9467_scale_fill() 415 if (!st->scales) in ad9467_scale_fill() 420 st->scales[i][0] = val1; in ad9467_scale_fill() 421 st->scales[i][1] = val2; in ad9467_scale_fill()
|
/kernel/linux/linux-6.6/drivers/iio/ |
H A D | industrialio-gts-helper.c | 168 static int gain_to_scaletables(struct iio_gts *gts, int **gains, int **scales) in gain_to_scaletables() argument 182 /* Convert gains to scales */ in gain_to_scaletables() 185 &scales[i][2 * j], in gain_to_scaletables() 186 &scales[i][2 * j + 1]); in gain_to_scaletables() 260 * iio_gts_build_avail_scale_table - create tables of available scales 263 * Build the tables which can represent the available scales based on the 266 * 1. A set of tables representing available scales for each supported 268 * 2. A single table listing all the unique scales that any combination of 417 * iio_gts_build_avail_tables - create tables of available scales and int times 420 * Build the tables which can represent the available scales an [all...] |
/kernel/linux/linux-6.6/drivers/hwmon/ |
H A D | nct6775-core.c | 1002 static inline long in_from_reg(u8 reg, u8 nr, const u16 *scales) in in_from_reg() argument 1004 return DIV_ROUND_CLOSEST(reg * scales[nr], 100); in in_from_reg() 1007 static inline u8 in_to_reg(u32 val, u8 nr, const u16 *scales) in in_to_reg() argument 1009 return clamp_val(DIV_ROUND_CLOSEST(val * 100, scales[nr]), 0, 255); in in_to_reg()
|
Completed in 10 milliseconds