linux-yocto/drivers/iio
Hans de Goede 9170730674 iio: consumers: Fix offset handling in iio_convert_raw_to_processed()
[ Upstream commit 33f5c69c4daff39c010b3ea6da8ebab285f4277b ]

Fix iio_convert_raw_to_processed() offset handling for channels without
a scale attribute.

The offset has been applied to the raw64 value not to the original raw
value. Use the raw64 value so that the offset is taken into account.

Fixes: 14b457fdde ("iio: inkern: apply consumer scale when no channel scale is available")
Cc: Liam Beguin <liambeguin@gmail.com>
Reviewed-by: Andy Shevchenko <andy@kernel.org>
Signed-off-by: Hans de Goede <hansg@kernel.org>
Link: https://patch.msgid.link/20250831104825.15097-3-hansg@kernel.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-10-15 11:58:00 +02:00
..
accel iio: accel: fxls8962af: Fix use after free in fxls8962af_fifo_flush 2025-07-24 08:53:15 +02:00
adc iio: adc: ad_sigma_delta: change to buffer predisable 2025-08-28 16:28:35 +02:00
addac
afe
amplifiers
buffer
cdc
chemical iio: chemical: pms7003: use aligned_s64 for timestamp 2025-09-09 18:56:30 +02:00
common
dac iio: dac: ad3552r: clear reset status flag 2025-03-13 12:58:38 +01:00
dummy
filter iio: filter: admv8818: Support frequencies >= 2^32 2025-06-19 15:28:30 +02:00
frequency
gyro
health
humidity
imu iio: imu: inv_mpu6050: align buffer for timestamp 2025-09-09 18:56:30 +02:00
light iio: light: opt3001: fix deadlock due to concurrent flag access 2025-09-09 18:56:30 +02:00
magnetometer
multiplexer
orientation
position
potentiometer
potentiostat
pressure iio: pressure: mprls0025pa: use aligned_s64 for timestamp 2025-09-09 18:56:30 +02:00
proximity iio: proximity: isl29501: fix buffered read on big-endian systems 2025-08-28 16:28:45 +02:00
resolver
temperature iio: temperature: maxim_thermocouple: use DMA-safe buffer for spi_read() 2025-08-28 16:28:47 +02:00
test
trigger
iio_core_trigger.h
iio_core.h
industrialio-backend.c
industrialio-buffer.c
industrialio-configfs.c
industrialio-core.c
industrialio-event.c
industrialio-gts-helper.c
industrialio-sw-device.c
industrialio-sw-trigger.c
industrialio-trigger.c
industrialio-triggered-event.c
inkern.c iio: consumers: Fix offset handling in iio_convert_raw_to_processed() 2025-10-15 11:58:00 +02:00
Kconfig
Makefile
TODO