]> www.infradead.org Git - users/jedix/linux-maple.git/commit
iio: pressure: Use iio_push_to_buffers_with_ts() to provide length for runtime checks.
authorJonathan Cameron <Jonathan.Cameron@huawei.com>
Sun, 13 Apr 2025 10:34:42 +0000 (11:34 +0100)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Wed, 21 May 2025 13:20:27 +0000 (14:20 +0100)
commit77e8a16a7d820af111679952ded15a795471abdd
treebfa1b7c4393ea83ca12fe07e1ec1396758b746f2
parent886a446b76afddfad307488e95e87f23a08ffd51
iio: pressure: Use iio_push_to_buffers_with_ts() to provide length for runtime checks.

This new function allows us to perform debug checks in the helper to ensure
that the overrun does not occur.  Use it in all the simple cases where
either a static buffer or a structure is used in the drivers.

Reviewed-by: Matti Vaittinen <mazziesaccount@gmail.com> # ROHM BM1390
Reviewed-by: David Lechner <dlechner@baylibre.com>
Link: https://patch.msgid.link/20250413103443.2420727-20-jic23@kernel.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/pressure/bmp280-core.c
drivers/iio/pressure/hid-sensor-press.c
drivers/iio/pressure/hsc030pa.c
drivers/iio/pressure/mpl3115.c
drivers/iio/pressure/rohm-bm1390.c
drivers/iio/pressure/zpa2326.c