acrn-kernel/drivers/iio
William Breathitt Gray 9fd4768b09 iio: addac: stx104: Fix race condition for stx104_write_raw()
commit 9740827468 upstream.

The priv->chan_out_states array and actual DAC value can become
mismatched if stx104_write_raw() is called concurrently. Prevent such a
race condition by utilizing a mutex.

Fixes: 97a445dad3 ("iio: Add IIO support for the DAC on the Apex Embedded Systems STX104")
Signed-off-by: William Breathitt Gray <william.gray@linaro.org>
Link: https://lore.kernel.org/r/c95c9a77fcef36b2a052282146950f23bbc1ebdc.1680790580.git.william.gray@linaro.org
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-05-11 23:03:01 +09:00
..
accel
adc iio: adc: palmas_gpadc: fix NULL dereference on rmmod 2023-05-11 23:02:58 +09:00
addac iio: addac: stx104: Fix race condition for stx104_write_raw() 2023-05-11 23:03:01 +09:00
afe
amplifiers
buffer
cdc
chemical
common
dac iio: dac: ad5755: Add missing fwnode_handle_put() 2023-04-26 14:28:37 +02:00
dummy
filter
frequency
gyro
health
humidity
imu
light iio: light: tsl2772: fix reading proximity-diodes from device tree 2023-04-26 14:28:38 +02:00
magnetometer
multiplexer
orientation
position
potentiometer
potentiostat
pressure
proximity
resolver
temperature
test
trigger
Kconfig
Makefile
TODO
iio_core.h
iio_core_trigger.h
industrialio-buffer.c iio: buffer: make sure O_NONBLOCK is respected 2023-04-13 16:55:27 +02:00
industrialio-configfs.c
industrialio-core.c
industrialio-event.c
industrialio-sw-device.c
industrialio-sw-trigger.c
industrialio-trigger.c
industrialio-triggered-event.c
inkern.c