linux-stable/include/linux/iio
Ramona Bolboaca b20d95a855 iio: adis: add '__adis_enable_irq()' implementation
[ Upstream commit 99c05e4283 ]

Add '__adis_enable_irq()' implementation which is the unlocked
version of 'adis_enable_irq()'.
Call '__adis_enable_irq()' instead of 'adis_enable_irq()' from
'__adis_intial_startup()' to keep the expected unlocked functionality.

This fix is needed to remove a deadlock for all devices which are
using 'adis_initial_startup()'. The deadlock occurs because the
same mutex is acquired twice, without releasing it.
The mutex is acquired once inside 'adis_initial_startup()', before
calling '__adis_initial_startup()', and once inside
'adis_enable_irq()', which is called by '__adis_initial_startup()'.
The deadlock is removed by calling '__adis_enable_irq()', instead of
'adis_enable_irq()' from within '__adis_initial_startup()'.

Fixes: b600bd7eb3 ("iio: adis: do not disabe IRQs in 'adis_init()'")
Signed-off-by: Ramona Bolboaca <ramona.bolboaca@analog.com>
Reviewed-by: Nuno Sá <nuno.sa@analog.com>
Link: https://lore.kernel.org/r/20221122082757.449452-2-ramona.bolboaca@analog.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-12-31 13:26:26 +01:00
..
accel
adc Char / Misc / Other smaller driver subsystem updates for 5.19-rc1 2022-06-03 11:36:34 -07:00
afe
common iio: cros: Register FIFO callback after sensor is registered 2022-07-18 18:29:13 +01:00
dac
frequency
gyro
imu iio: adis: add '__adis_enable_irq()' implementation 2022-12-31 13:26:26 +01:00
timer
buffer-dma.h
buffer-dmaengine.h
buffer.h
buffer_impl.h
configfs.h
consumer.h
driver.h
events.h
hw-consumer.h
iio-opaque.h iio: Use per-device lockdep class for mlock 2022-10-21 12:38:43 +02:00
iio.h iio: trigger: move trig->owner init to trigger allocate() stage 2022-07-16 16:24:19 +01:00
kfifo_buf.h iio: core: Simplify the registration of kfifo buffers 2022-04-10 16:25:46 +01:00
machine.h
sw_device.h
sw_trigger.h
sysfs.h
trigger.h iio: trigger: move trig->owner init to trigger allocate() stage 2022-07-16 16:24:19 +01:00
trigger_consumer.h
triggered_buffer.h
triggered_event.h
types.h