linux-stable/drivers/iio
Liam Beguin 51593106b6 iio: afe: rescale: use s64 for temporary scale calculations
All four scaling coefficients can take signed values.
Make tmp a signed 64-bit integer and switch to div_s64() to preserve
signs during 64-bit divisions.

Fixes: 8b74816b5a ("iio: afe: rescale: new driver")
Signed-off-by: Liam Beguin <liambeguin@gmail.com>
Reviewed-by: Peter Rosin <peda@axentia.se>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/20220108205319.2046348-5-liambeguin@gmail.com
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
2022-01-30 14:38:03 +00:00
..
accel iio: st_sensors: don't always auto-enable I2C and SPI interface drivers 2022-01-23 18:03:35 +00:00
adc iio: adc: qcom-vadc-common: Re-use generic struct u32_fract 2022-01-30 12:21:25 +00:00
addac iio:addac:ad74413r: Fix uninitialized ret in a path that won't be hit. 2021-12-21 15:10:10 +00:00
afe iio: afe: rescale: use s64 for temporary scale calculations 2022-01-30 14:38:03 +00:00
amplifiers iio:amplifiers:hmc425a: Suppress clang W=1 warning about pointer to enum conversion. 2021-12-21 15:10:09 +00:00
buffer iio: hw_consumer: Use struct_size() helper in kzalloc() 2022-01-23 18:03:37 +00:00
cdc iio:cdc:ad7150: Fix use of uninitialized ret 2021-04-07 08:36:39 +01:00
chemical iio: sps30: Use sysfs_emit() 2022-01-23 18:03:37 +00:00
common iio: ms_sensors: Use sysfs_emit() 2022-01-23 18:03:36 +00:00
dac iio:dac:mcp4725: Suppress clang W=1 warning about pointer to enum conversion. 2021-12-21 15:10:09 +00:00
dummy iio:dummy: Drop set but unused variable len. 2021-12-21 15:10:09 +00:00
filter iio:filter:admv8818: add support for ADMV8818 2021-12-16 17:34:28 +00:00
frequency iio: ad9523: Use sysfs_emit() 2022-01-23 18:03:36 +00:00
gyro iio: st_sensors: don't always auto-enable I2C and SPI interface drivers 2022-01-23 18:03:35 +00:00
health iio: afe4404: Remove no-op trigger ops 2021-11-17 17:51:37 +00:00
humidity iio: humidity: hdc100x: Add ACPI HID table 2022-01-30 13:44:53 +00:00
imu iio: adis: stylistic changes 2022-01-23 18:03:37 +00:00
light iio: lm3533: Use sysfs_emit() 2022-01-23 18:03:36 +00:00
magnetometer iio: st_sensors: don't always auto-enable I2C and SPI interface drivers 2022-01-23 18:03:35 +00:00
multiplexer iio: multiplexer: iio-mux: Support settle-time-us property 2021-10-21 20:02:54 +01: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:pot:mcp41010: Switch to generic firmware properties. 2021-12-12 17:12:47 +00:00
potentiostat iio: lmp91000: Remove no-op trigger ops 2021-11-17 17:51:38 +00:00
pressure iio: pressure: dps310: Add ACPI HID table 2022-01-30 12:55:11 +00:00
proximity iio: sx9360: fix iio event generation 2022-01-30 12:39:16 +00:00
resolver iio:resolver:ad2s1200: Drop of_match_ptr protection 2020-09-21 18:41:31 +01:00
temperature iio: max31865: Use sysfs_emit() 2022-01-23 18:03:36 +00:00
test iio: test: Add test for IIO_VAL_INT_64. 2021-11-27 16:33:45 +00:00
trigger 1st set of IIO new device support, features and cleanup for 5.17 2021-12-22 12:33:01 +01:00
iio_core.h iio: Mark iio_device_type as const 2021-11-17 17:51:35 +00:00
iio_core_trigger.h iio: core-trigger: make iio_device_register_trigger_consumer() an int return 2021-03-11 20:47:02 +00:00
industrialio-buffer.c iio: core: Use sysfs_emit() 2022-01-23 18:03:36 +00:00
industrialio-configfs.c
industrialio-core.c iio: core: Use sysfs_emit() 2022-01-23 18:03:36 +00:00
industrialio-event.c iio:event: Add timeout event info type 2021-04-07 08:36:36 +01:00
industrialio-sw-device.c
industrialio-sw-trigger.c
industrialio-trigger.c 1st set of IIO new device support, features and cleanup for 5.17 2021-12-22 12:33:01 +01:00
industrialio-triggered-event.c iio: core: move @id from struct iio_dev to struct iio_dev_opaque 2021-05-17 13:49:13 +01:00
inkern.c iio: inkern: make a best effort on offset calculation 2022-01-30 14:38:03 +00: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: add a TODO 2020-03-08 17:28:53 +00:00