diff options
author | Noralf Trønnes <noralf@tronnes.org> | 2021-10-18 13:37:31 +0200 |
---|---|---|
committer | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2021-11-17 18:52:35 +0100 |
commit | 59f92868176f191eefde70d284bdfc1ed76a84bc (patch) | |
tree | 155d89440f34ddc19acf4bd77e715794229ef1a3 /arch/sparc/mm/tlb.c | |
parent | iio: adc: stm32: fix a current leak by resetting pcsel before disabling vdda (diff) | |
download | linux-59f92868176f191eefde70d284bdfc1ed76a84bc.tar.xz linux-59f92868176f191eefde70d284bdfc1ed76a84bc.zip |
iio: dln2-adc: Fix lockdep complaint
When reading the voltage:
$ cat /sys/bus/iio/devices/iio\:device0/in_voltage0_raw
Lockdep complains:
[ 153.910616] ======================================================
[ 153.916918] WARNING: possible circular locking dependency detected
[ 153.923221] 5.14.0+ #5 Not tainted
[ 153.926692] ------------------------------------------------------
[ 153.932992] cat/717 is trying to acquire lock:
[ 153.937525] c2585358 (&indio_dev->mlock){+.+.}-{3:3}, at: iio_device_claim_direct_mode+0x28/0x44
[ 153.946541]
but task is already holding lock:
[ 153.952487] c2585860 (&dln2->mutex){+.+.}-{3:3}, at: dln2_adc_read_raw+0x94/0x2bc [dln2_adc]
[ 153.961152]
which lock already depends on the new lock.
Fix this by not calling into the iio core underneath the dln2->mutex lock.
Fixes: 7c0299e879dd ("iio: adc: Add support for DLN2 ADC")
Cc: Jack Andersen <jackoalan@gmail.com>
Signed-off-by: Noralf Trønnes <noralf@tronnes.org>
Link: https://lore.kernel.org/r/20211018113731.25723-1-noralf@tronnes.org
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'arch/sparc/mm/tlb.c')
0 files changed, 0 insertions, 0 deletions