linux/drivers/iio/magnetometer
Zheyu Ma ca2b54b6ad iio: magnetometer: ak8975: Fix the error handling in ak8975_power_on()
commit 3a26787dac upstream.

When the driver fails to enable the regulator 'vid', we will get the
following splat:

[   79.955610] WARNING: CPU: 5 PID: 441 at drivers/regulator/core.c:2257 _regulator_put+0x3ec/0x4e0
[   79.959641] RIP: 0010:_regulator_put+0x3ec/0x4e0
[   79.967570] Call Trace:
[   79.967773]  <TASK>
[   79.967951]  regulator_put+0x1f/0x30
[   79.968254]  devres_release_group+0x319/0x3d0
[   79.968608]  i2c_device_probe+0x766/0x940

Fix this by disabling the 'vdd' regulator when failing to enable 'vid'
regulator.

Signed-off-by: Zheyu Ma <zheyuma97@gmail.com>
Link: https://lore.kernel.org/r/20220409034849.3717231-2-zheyuma97@gmail.com
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-05-09 09:04:58 +02:00
..
ak8974.c Second set of features and cleanups for IIO in 5.10 2020-09-22 09:45:11 +02:00
ak8975.c iio: magnetometer: ak8975: Fix the error handling in ak8975_power_on() 2022-05-09 09:04:58 +02:00
bmc150_magn_i2c.c iio: magnetometer: bmc150: Add proper compatible for BMM150 2020-07-07 20:24:07 +01:00
bmc150_magn_spi.c
bmc150_magn.c iio: Fix error handling for PM 2022-03-02 11:42:53 +01:00
bmc150_magn.h
hid-sensor-magn-3d.c iio: remove explicit IIO device parent assignment 2020-06-14 11:49:59 +01:00
hmc5843_core.c iio: magn: hmc5843: Fix buffer alignment in iio_push_to_buffers_with_timestamp() 2021-07-14 16:56:36 +02:00
hmc5843_i2c.c
hmc5843_spi.c
hmc5843.h iio: magn: hmc5843: Fix buffer alignment in iio_push_to_buffers_with_timestamp() 2021-07-14 16:56:36 +02:00
Kconfig iio: hid-sensors: select IIO_TRIGGERED_BUFFER under HID_SENSOR_IIO_TRIGGER 2021-05-19 10:13:13 +02:00
mag3110.c iio:magnetometer:mag3110: Fix alignment and data leak issues. 2020-12-30 11:54:24 +01:00
Makefile
mmc35240.c iio: magnetometer: mmc35240: Fix function header formatting 2020-07-20 09:03:08 +01:00
rm3100-core.c iio: magn: rm3100: Fix alignment of buffer in iio_push_to_buffers_with_timestamp() 2021-07-14 16:56:45 +02:00
rm3100-i2c.c
rm3100-spi.c
rm3100.h
st_magn_buffer.c iio: Move attach/detach of the poll func to the core 2020-06-20 17:34:44 +01:00
st_magn_core.c iio: st_sensors: Call st_sensors_power_enable() from bus drivers 2021-11-18 14:04:13 +01:00
st_magn_i2c.c iio: st_sensors: disable regulators after device unregistration 2021-11-18 14:04:13 +01:00
st_magn_spi.c iio: st_sensors: disable regulators after device unregistration 2021-11-18 14:04:13 +01:00
st_magn.h