linux/drivers/iio/temperature
Dimitri Fedrau 827dca3129 iio: temperature: mcp9600: Fix temperature reading for negative values
Temperature is stored as 16bit value in two's complement format. Current
implementation ignores the sign bit. Make it aware of the sign bit by
using sign_extend32.

Fixes: 3f6b9598b6 ("iio: temperature: Add MCP9600 thermocouple EMF converter")
Signed-off-by: Dimitri Fedrau <dima.fedrau@gmail.com>
Reviewed-by: Marcelo Schmitt <marcelo.schmitt1@gmail.com>
Tested-by: Andrew Hepp <andrew.hepp@ahepp.dev>
Link: https://lore.kernel.org/r/20240424185913.1177127-1-dima.fedrau@gmail.com
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
2024-05-03 11:48:56 +01:00
..
hid-sensor-temperature.c iio: temperature: hid-sensor: Convert to platform remove callback returning void 2023-09-23 15:06:56 +01:00
iqs620at-temp.c iio: temperature: iqs620at-temp: Add support for V3 silicon 2022-02-14 13:07:33 +00:00
Kconfig iio: temperature: mlx90635 MLX90635 IR Temperature sensor 2023-12-11 19:16:34 +00:00
ltc2983.c iio: temperature: ltc2983: support vdd regulator 2024-04-06 16:49:24 +01:00
Makefile iio: temperature: mlx90635 MLX90635 IR Temperature sensor 2023-12-11 19:16:34 +00:00
max30208.c iio: Switch i2c drivers back to use .probe() 2023-05-21 18:54:53 +01:00
max31856.c iio: temperature: max31856: Make use of device properties 2022-04-28 19:22:55 +01:00
max31865.c iio: temp: max31865: Fix alignment for DMA safety 2022-06-14 11:53:19 +01:00
maxim_thermocouple.c iio: temp: maxim_thermocouple: Fix alignment for DMA safety 2022-06-14 11:53:19 +01:00
mcp9600.c iio: temperature: mcp9600: Fix temperature reading for negative values 2024-05-03 11:48:56 +01:00
mlx90614.c iio: mlx90614: Use i2c_get_match_data() 2023-09-11 20:12:42 +01:00
mlx90632.c iio: Switch i2c drivers back to use .probe() 2023-05-21 18:54:53 +01:00
mlx90635.c iio: temperature: mlx90635 MLX90635 IR Temperature sensor 2023-12-11 19:16:34 +00:00
tmp006.c iio: temperature: tmp006: Add OF device matching support 2023-05-28 20:22:03 +01:00
tmp007.c iio: Switch i2c drivers back to use .probe() 2023-05-21 18:54:53 +01:00
tmp117.c iio: temperature: tmp117: add support for vcc-supply 2024-02-28 19:26:35 +00:00
tsys01.c iio: Switch i2c drivers back to use .probe() 2023-05-21 18:54:53 +01:00
tsys02d.c iio: Switch i2c drivers back to use .probe() 2023-05-21 18:54:53 +01:00