linux/drivers/iio/temperature
David Lechner c456108605 iio: temperature: maxim_thermocouple: use DMA-safe buffer for spi_read()
[ Upstream commit ae5bc07ec9 ]

Replace using stack-allocated buffers with a DMA-safe buffer for use
with spi_read(). This allows the driver to be safely used with
DMA-enabled SPI controllers.

The buffer array is also converted to a struct with a union to make the
usage of the memory in the buffer more clear and ensure proper alignment.

Fixes: 1f25ca11d8 ("iio: temperature: add support for Maxim thermocouple chips")
Signed-off-by: David Lechner <dlechner@baylibre.com>
Reviewed-by: Nuno Sá <nuno.sa@analog.com>
Link: https://patch.msgid.link/20250721-iio-use-more-iio_declare_buffer_with_ts-3-v2-1-0c68d41ccf6c@baylibre.com
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
[ iio_push_to_buffers_with_ts() => iio_push_to_buffers_with_timestamp() ]
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
History 2025-08-28 16:31:10 +02: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 move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
Makefile iio: temperature: mlx90635 MLX90635 IR Temperature sensor 2023-12-11 19:16:34 +00:00
max30208.c iio: temperature: max30208: Remove an unused field in struct max30208_data 2024-05-27 09:48:56 +01:00
max31856.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
max31865.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
maxim_thermocouple.c iio: temperature: maxim_thermocouple: use DMA-safe buffer for spi_read() 2025-08-28 16:31:10 +02:00
mcp9600.c iio: temperature: mcp9600: add threshold events support 2024-06-13 19:19:25 +01:00
mlx90614.c iio: mlx90614: Use i2c_get_match_data() 2023-09-11 20:12:42 +01:00
mlx90632.c iio: temperature: mlx90632: make use of regmap_clear_bits() 2024-06-25 21:04:48 +01:00
mlx90635.c iio: temperature: mlx90635: Fix ERR_PTR dereference in mlx90635_probe() 2024-05-27 09:49:20 +01:00
tmp006.c iio: Drop explicit initialization of struct i2c_device_id::driver_data to 0 2024-05-27 09:48:57 +01:00
tmp007.c iio: Drop explicit initialization of struct i2c_device_id::driver_data to 0 2024-05-27 09:48:57 +01:00
tmp117.c iio: temperature: tmp117: add support for vcc-supply 2024-02-28 19:26:35 +00:00
tsys01.c iio: Drop explicit initialization of struct i2c_device_id::driver_data to 0 2024-05-27 09:48:57 +01:00
tsys02d.c iio: Drop explicit initialization of struct i2c_device_id::driver_data to 0 2024-05-27 09:48:57 +01:00