Home
last modified time | relevance | path

Searched refs:scan_type (Results 1 – 25 of 142) sorted by relevance

123456

/linux-4.19.296/drivers/iio/pressure/
Dcros_ec_baro.c157 channel->scan_type.realbits = CROS_EC_SENSOR_BITS; in cros_ec_baro_probe()
158 channel->scan_type.storagebits = CROS_EC_SENSOR_BITS; in cros_ec_baro_probe()
159 channel->scan_type.shift = 0; in cros_ec_baro_probe()
162 channel->scan_type.sign = 'u'; in cros_ec_baro_probe()
181 channel->scan_type.sign = 's'; in cros_ec_baro_probe()
182 channel->scan_type.realbits = 64; in cros_ec_baro_probe()
183 channel->scan_type.storagebits = 64; in cros_ec_baro_probe()
Dst_pressure_core.c138 .scan_type = {
152 .scan_type = {
172 .scan_type = {
186 .scan_type = {
204 .scan_type = {
219 .scan_type = {
/linux-4.19.296/drivers/iio/light/
Dcros_ec_light_prox.c211 channel->scan_type.realbits = CROS_EC_SENSOR_BITS; in cros_ec_light_prox_probe()
212 channel->scan_type.storagebits = CROS_EC_SENSOR_BITS; in cros_ec_light_prox_probe()
213 channel->scan_type.shift = 0; in cros_ec_light_prox_probe()
216 channel->scan_type.sign = 'u'; in cros_ec_light_prox_probe()
246 channel->scan_type.sign = 's'; in cros_ec_light_prox_probe()
247 channel->scan_type.realbits = 64; in cros_ec_light_prox_probe()
248 channel->scan_type.storagebits = 64; in cros_ec_light_prox_probe()
/linux-4.19.296/drivers/iio/common/st_sensors/
Dst_sensors_buffer.c34 DIV_ROUND_UP(channel->scan_type.realbits + in st_sensors_get_buffer_element()
35 channel->scan_type.shift, 8); in st_sensors_get_buffer_element()
37 channel->scan_type.storagebits >> 3; in st_sensors_get_buffer_element()
/linux-4.19.296/drivers/iio/adc/
Dti-adc161s626.c39 .scan_type = {
56 .scan_type = {
106 *val = sign_extend32(*val >> data->shift, chan->scan_type.realbits - 1); in ti_adc_read_measurement()
156 *val2 = chan->scan_type.realbits; in ti_adc_read_raw()
160 *val = 1 << (chan->scan_type.realbits - 1); in ti_adc_read_raw()
Dcc10001_adc.c243 *val2 = chan->scan_type.realbits; in cc10001_adc_read_raw()
291 chan->scan_type.sign = 'u'; in cc10001_adc_channel_init()
292 chan->scan_type.realbits = 10; in cc10001_adc_channel_init()
293 chan->scan_type.storagebits = 16; in cc10001_adc_channel_init()
303 timestamp->scan_type.sign = 's'; in cc10001_adc_channel_init()
304 timestamp->scan_type.realbits = 64; in cc10001_adc_channel_init()
305 timestamp->scan_type.storagebits = 64; in cc10001_adc_channel_init()
Dad7476.c120 *val = (ret >> st->chip_info->channel[0].scan_type.shift) & in ad7476_read_raw()
121 GENMASK(st->chip_info->channel[0].scan_type.realbits - 1, 0); in ad7476_read_raw()
132 *val2 = chan->scan_type.realbits; in ad7476_read_raw()
144 .scan_type = { \
255 st->xfer.len = st->chip_info->channel[0].scan_type.storagebits / 8; in ad7476_probe()
Dti-tlc4541.c64 .scan_type = { \
144 *val = *val >> chan->scan_type.shift; in tlc4541_read_raw()
145 *val &= GENMASK(chan->scan_type.realbits - 1, 0); in tlc4541_read_raw()
152 *val2 = chan->scan_type.realbits; in tlc4541_read_raw()
Dad7887.c167 *val = ret >> chan->scan_type.shift; in ad7887_read_raw()
168 *val &= GENMASK(chan->scan_type.realbits - 1, 0); in ad7887_read_raw()
180 *val2 = chan->scan_type.realbits; in ad7887_read_raw()
201 .scan_type = {
217 .scan_type = {
Dad_sigma_delta.c310 DIV_ROUND_UP(chan->scan_type.realbits + chan->scan_type.shift, 8), in ad_sigma_delta_single_conversion()
328 sample = raw_sample >> chan->scan_type.shift; in ad_sigma_delta_single_conversion()
329 sample &= (1 << chan->scan_type.realbits) - 1; in ad_sigma_delta_single_conversion()
407 reg_size = indio_dev->channels[0].scan_type.realbits + in ad_sd_trigger_handler()
408 indio_dev->channels[0].scan_type.shift; in ad_sd_trigger_handler()
Dad799x.c293 *val = (ret >> chan->scan_type.shift) & in ad799x_read_raw()
294 GENMASK(chan->scan_type.realbits - 1, 0); in ad799x_read_raw()
301 *val2 = chan->scan_type.realbits; in ad799x_read_raw()
445 if (val < 0 || val > GENMASK(chan->scan_type.realbits - 1, 0)) in ad799x_write_event_value()
451 val << chan->scan_type.shift); in ad799x_write_event_value()
473 *val = (ret >> chan->scan_type.shift) & in ad799x_read_event_value()
474 GENMASK(chan->scan_type.realbits - 1, 0); in ad799x_read_event_value()
572 .scan_type = { \
Dti-ads1015.c148 .scan_type = { \
171 .scan_type = { \
192 .scan_type = { \
214 .scan_type = { \
430 (chan->scan_type.realbits - 1), 1000000); in ads1015_set_scale()
466 int shift = chan->scan_type.shift; in ads1015_read_raw()
502 *val2 = chan->scan_type.realbits - 1; in ads1015_read_raw()
589 int realbits = chan->scan_type.realbits; in ads1015_write_event()
673 low_thresh = max(-1 << (chan->scan_type.realbits - 1), in ads1015_enable_event_config()
677 low_thresh << chan->scan_type.shift); in ads1015_enable_event_config()
[all …]
/linux-4.19.296/drivers/iio/dac/
Dad5360.c110 .scan_type = { \
318 int max_val = (1 << chan->scan_type.realbits); in ad5360_write_raw()
327 chan->address, val, chan->scan_type.shift); in ad5360_write_raw()
334 chan->address, val, chan->scan_type.shift); in ad5360_write_raw()
341 chan->address, val, chan->scan_type.shift); in ad5360_write_raw()
352 val >>= (chan->scan_type.realbits - 14); in ad5360_write_raw()
384 *val = ret >> chan->scan_type.shift; in ad5360_read_raw()
393 *val2 = chan->scan_type.realbits; in ad5360_read_raw()
416 ret <<= (chan->scan_type.realbits - 14); in ad5360_read_raw()
Dad5380.c177 const unsigned int max_val = (1 << chan->scan_type.realbits); in ad5380_write_raw()
188 val << chan->scan_type.shift); in ad5380_write_raw()
190 val += (1 << chan->scan_type.realbits) / 2; in ad5380_write_raw()
196 val << chan->scan_type.shift); in ad5380_write_raw()
216 *val >>= chan->scan_type.shift; in ad5380_read_raw()
223 *val >>= chan->scan_type.shift; in ad5380_read_raw()
224 *val -= (1 << chan->scan_type.realbits) / 2; in ad5380_read_raw()
228 *val2 = chan->scan_type.realbits; in ad5380_read_raw()
263 .scan_type = { \
Dad5764.c86 .scan_type = { \
187 const int max_val = (1 << chan->scan_type.realbits); in ad5764_write_raw()
194 val <<= chan->scan_type.shift; in ad5764_write_raw()
235 *val >>= chan->scan_type.shift; in ad5764_read_raw()
258 *val2 = chan->scan_type.realbits; in ad5764_read_raw()
261 *val = -(1 << chan->scan_type.realbits) / 2; in ad5764_read_raw()
Dmcp4922.c52 .scan_type = { \
83 *val2 = chan->scan_type.realbits; in mcp4922_read_raw()
104 if (val < 0 || val > GENMASK(chan->scan_type.realbits - 1, 0)) in mcp4922_write_raw()
106 val <<= chan->scan_type.shift; in mcp4922_write_raw()
Dad5761.c213 *val = aux >> chan->scan_type.shift; in ad5761_read_raw()
219 *val2 = chan->scan_type.realbits; in ad5761_read_raw()
223 *val = -(1 << chan->scan_type.realbits); in ad5761_read_raw()
243 if (val2 || (val << chan->scan_type.shift) > 0xffff || val < 0) in ad5761_write_raw()
246 aux = val << chan->scan_type.shift; in ad5761_write_raw()
262 .scan_type = { \
Dad5446.c118 shift = chan->scan_type.realbits + chan->scan_type.shift; in ad5446_write_dac_powerdown()
149 .scan_type = { \
174 *val = st->cached_val >> chan->scan_type.shift; in ad5446_read_raw()
178 *val2 = chan->scan_type.realbits; in ad5446_read_raw()
195 if (val >= (1 << chan->scan_type.realbits) || val < 0) in ad5446_write_raw()
198 val <<= chan->scan_type.shift; in ad5446_write_raw()
Dad5791.c265 *val >>= chan->scan_type.shift; in ad5791_read_raw()
269 *val2 = (1 << chan->scan_type.realbits) - 1; in ad5791_read_raw()
272 val64 = (((u64)st->vref_neg_mv) << chan->scan_type.realbits); in ad5791_read_raw()
304 .scan_type = { \
330 val &= GENMASK(chan->scan_type.realbits - 1, 0); in ad5791_write_raw()
331 val <<= chan->scan_type.shift; in ad5791_write_raw()
Dad5686.c127 *val = (ret >> chan->scan_type.shift) & in ad5686_read_raw()
128 GENMASK(chan->scan_type.realbits - 1, 0); in ad5686_read_raw()
132 *val2 = chan->scan_type.realbits; in ad5686_read_raw()
149 if (val > (1 << chan->scan_type.realbits) || val < 0) in ad5686_write_raw()
156 val << chan->scan_type.shift); in ad5686_write_raw()
191 .scan_type = { \
Dad5624r_spi.c57 *val2 = chan->scan_type.realbits; in ad5624r_read_raw()
73 if (val >= (1 << chan->scan_type.realbits) || val < 0) in ad5624r_write_raw()
79 chan->scan_type.shift); in ad5624r_write_raw()
175 .scan_type = { \
/linux-4.19.296/drivers/iio/common/cros_ec_sensors/
Dcros_ec_sensors.c224 channel->scan_type.realbits = CROS_EC_SENSOR_BITS; in cros_ec_sensors_probe()
225 channel->scan_type.storagebits = CROS_EC_SENSOR_BITS; in cros_ec_sensors_probe()
230 channel->scan_type.sign = 's'; in cros_ec_sensors_probe()
253 channel->scan_type.sign = 's'; in cros_ec_sensors_probe()
254 channel->scan_type.realbits = 64; in cros_ec_sensors_probe()
255 channel->scan_type.storagebits = 64; in cros_ec_sensors_probe()
/linux-4.19.296/drivers/iio/temperature/
Dmaxim_thermocouple.c33 .scan_type = {
51 .scan_type = {
67 .scan_type = {
117 unsigned int shift = chan->scan_type.shift + (chan->address * 8); in maxim_thermocouple_read()
142 *val = sign_extend32(*val >> shift, chan->scan_type.realbits - 1); in maxim_thermocouple_read()
/linux-4.19.296/drivers/iio/common/ssp_sensors/
Dssp_iio_sensor.h12 .scan_type = {\
26 .scan_type = { \
/linux-4.19.296/drivers/iio/
Dindustrialio-buffer.c237 u8 type = this_attr->c->scan_type.endianness; in iio_show_fixed_type()
246 if (this_attr->c->scan_type.repeat > 1) in iio_show_fixed_type()
249 this_attr->c->scan_type.sign, in iio_show_fixed_type()
250 this_attr->c->scan_type.realbits, in iio_show_fixed_type()
251 this_attr->c->scan_type.storagebits, in iio_show_fixed_type()
252 this_attr->c->scan_type.repeat, in iio_show_fixed_type()
253 this_attr->c->scan_type.shift); in iio_show_fixed_type()
257 this_attr->c->scan_type.sign, in iio_show_fixed_type()
258 this_attr->c->scan_type.realbits, in iio_show_fixed_type()
259 this_attr->c->scan_type.storagebits, in iio_show_fixed_type()
[all …]

123456