linux-stable/drivers/iio
Olivier Moysan 9d901e356c iio: adc: stm32-adc: smart calibration support
Add smart calibration support for STM32MP1.
- STM32MP15x: both linear & offset calibration are supported
- STM32MP13x: Only offset calibration is supported

Linear calibration:
Linear calibration is SoC dependent and does not change over time
so it can be done only once.
Linear calibration may have already been done in u-boot.
Skip calibration execution if calibration data are already available.
Save calibration factors in private data and restore them from private
data on next ADC start.

Offset calibration:
This calibration may vary over time, depending on temperature or voltage.
Run offset single-ended and differential calibration on each ADC start,
as it is not time consuming. This calibration do not need to be saved.
So, remove calfact_s and calfact_d value and bitfields that are no
longer used.

Signed-off-by: Olivier Moysan <olivier.moysan@foss.st.com>
Reviewed-by: Fabrice Gasnier <fabrice.gasnier@foss.st.com>
Link: https://lore.kernel.org/r/20221115103124.70074-2-olivier.moysan@foss.st.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
2022-11-23 20:56:13 +00:00
..
accel iio: accel: adis16209: Call '__adis_initial_startup()' in probe 2022-11-23 20:37:50 +00:00
adc iio: adc: stm32-adc: smart calibration support 2022-11-23 20:56:13 +00:00
addac iio: addac: ad74413r: add support for reset-gpio 2022-11-23 20:54:37 +00:00
afe iio: afe: rescale: export symbols used during testing 2022-07-16 19:01:14 +01:00
amplifiers iio: amplifier: hmc425a: simplify using devm_regulator_get_enable() 2022-11-23 19:44:01 +00:00
buffer iio: Don't silently expect attribute types 2022-11-23 19:44:04 +00:00
cdc iio: cdc: ad7746: Convert to i2c's .probe_new() 2022-11-23 20:01:40 +00:00
chemical iio: chemical: vz89x: Convert to i2c's .probe_new() 2022-11-23 20:01:40 +00:00
common iio: Don't silently expect attribute types 2022-11-23 19:44:04 +00:00
dac iio: dac: ti-dac5571: Convert to i2c's .probe_new() 2022-11-23 20:01:41 +00:00
dummy Bitmap patches for 5.19-rc1 2022-06-04 14:04:27 -07:00
filter iio: filter: admv8818: close potential out-of-bounds read in __admv8818_read_[h|l]pf_freq() 2022-11-23 19:43:57 +00:00
frequency iio: frequency: ad9523: Use devm_regulator_get_enable() 2022-11-23 19:44:01 +00:00
gyro iio: gyro: adis16260: Call '__adis_initial_startup()' in probe 2022-11-23 20:37:51 +00:00
health iio: health: max30102: Convert to i2c's .probe_new() 2022-11-23 20:01:42 +00:00
humidity iio: humidity: si7020: Convert to i2c's .probe_new() 2022-11-23 20:01:42 +00:00
imu iio: imu: st_lsm6dsx: add support to LSM6DSO16IS 2022-11-23 20:50:37 +00:00
light iio: light: zopt2201: Convert to i2c's .probe_new() 2022-11-23 20:20:29 +00:00
magnetometer iio: magnetometer: yamaha-yas530: Convert to i2c's .probe_new() 2022-11-23 20:20:30 +00:00
multiplexer iio: multiplexer: Switch to use dev_err_probe() helper 2022-11-23 19:43:57 +00:00
orientation iio: hid-sensors: bind IIO channels alloc to device object 2021-07-13 18:21:53 +01:00
position iio: hid-sensors: Update header includes 2021-06-16 14:53:13 +01:00
potentiometer iio: potentiometer: tpl0102: Convert to i2c's .probe_new() 2022-11-23 20:20:30 +00:00
potentiostat iio: potentiostat: lmp91000: Convert to i2c's .probe_new() 2022-11-23 20:20:30 +00:00
pressure iio: pressure: zpa2326_i2c: Convert to i2c's .probe_new() 2022-11-23 20:20:31 +00:00
proximity iio: proximity: sx9500: Convert to i2c's .probe_new() 2022-11-23 20:20:31 +00:00
resolver iio: resolver: ad2s90: Fix alignment for DMA safety 2022-06-14 11:53:19 +01:00
temperature iio: temperature: Add driver support for Maxim MAX30208 2022-11-23 20:20:32 +00:00
test iio: test: Mark file local structure arrays static. 2022-08-15 22:30:01 +01:00
trigger iio: trigger: sysfs: rename error label in iio_sysfs_trigger_probe() 2022-11-23 19:44:03 +00:00
iio_core.h iio: Mark iio_device_type as const 2021-11-17 17:51:35 +00:00
iio_core_trigger.h
industrialio-buffer.c iio: Don't silently expect attribute types 2022-11-23 19:44:04 +00:00
industrialio-configfs.c
industrialio-core.c iio: core: move 'mlock' to 'struct iio_dev_opaque' 2022-11-23 19:44:00 +00:00
industrialio-event.c iio: core: move 'mlock' to 'struct iio_dev_opaque' 2022-11-23 19:44:00 +00:00
industrialio-sw-device.c iio: Don't use bare "unsigned" 2022-07-01 11:19:08 +01:00
industrialio-sw-trigger.c iio: Don't use bare "unsigned" 2022-07-01 11:19:08 +01:00
industrialio-trigger.c iio: core: move 'mlock' to 'struct iio_dev_opaque' 2022-11-23 19:44:00 +00:00
industrialio-triggered-event.c
inkern.c iio: inkern: fix coding style warnings 2022-08-15 22:30:00 +01:00
Kconfig iio: add filter subfolder 2021-12-16 17:29:46 +00:00
Makefile iio: add filter subfolder 2021-12-16 17:29:46 +00:00
TODO iio: core: move 'mlock' to 'struct iio_dev_opaque' 2022-11-23 19:44:00 +00:00