linux-brain/drivers/iio/magnetometer
Jonathan Cameron 7dff52b311 iio: magn: bmc150: Balance runtime pm + use pm_runtime_resume_and_get()
[ Upstream commit 264da512431495e542fcaf56ffe75e7df0e7db74 ]

probe() error paths after runtime pm is enabled, should disable it.
remove() should not call pm_runtime_put_noidle() as there is no
matching get() to have raised the reference count.  This case
has no affect a the runtime pm core protects against going negative.

Whilst here use pm_runtime_resume_and_get() to tidy things up a little.
coccicheck script didn't get this one due to complex code structure so
found by inspection.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Linus Walleij <linus.walleij@linaro.org>
Reviewed-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Link: https://lore.kernel.org/r/20210509113354.660190-12-jic23@kernel.org
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-07-20 16:10:41 +02:00
..
Kconfig treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
Makefile iio: magnetometer: Add driver support for PNI RM3100 2018-11-16 18:32:31 +00:00
ak8974.c iio: magnetometer: ak8974: Fix runtime PM imbalance on error 2020-07-22 09:32:54 +02:00
ak8975.c iio:magnetometer:ak8975 Fix alignment and data leak issues. 2020-09-17 13:47:50 +02:00
bmc150_magn.c iio: magn: bmc150: Balance runtime pm + use pm_runtime_resume_and_get() 2021-07-20 16:10:41 +02:00
bmc150_magn.h License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
bmc150_magn_i2c.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 288 2019-06-05 17:36:37 +02:00
bmc150_magn_spi.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 330 2019-06-05 17:37:06 +02:00
hid-sensor-magn-3d.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 335 2019-06-05 17:37:06 +02:00
hmc5843.h iio: magn: hmc5843: Fix buffer alignment in iio_push_to_buffers_with_timestamp() 2021-07-14 16:53:39 +02:00
hmc5843_core.c iio: magn: hmc5843: Fix buffer alignment in iio_push_to_buffers_with_timestamp() 2021-07-14 16:53:39 +02:00
hmc5843_i2c.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
hmc5843_spi.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
mag3110.c iio:magnetometer:mag3110: Fix alignment and data leak issues. 2020-12-30 11:51:44 +01:00
mmc35240.c iio: magnetometer: mmc35240: Fix a typo in the name of a constant 2019-07-27 22:52:07 +01:00
rm3100-core.c iio: magn: rm3100: Fix alignment of buffer in iio_push_to_buffers_with_timestamp() 2021-07-14 16:53:43 +02:00
rm3100-i2c.c iio: magnetometer: Add driver support for PNI RM3100 2018-11-16 18:32:31 +00:00
rm3100-spi.c iio: magnetometer: Add driver support for PNI RM3100 2018-11-16 18:32:31 +00:00
rm3100.h iio: magnetometer: Add driver support for PNI RM3100 2018-11-16 18:32:31 +00:00
st_magn.h iio:magn: introduce st_magn_get_settings() function 2019-07-27 22:52:05 +01:00
st_magn_buffer.c iio:st_sensors: remove buffer allocation at each buffer enable 2019-08-11 09:26:04 +01:00
st_magn_core.c iio: remove get_irq_data_ready() function pointer and use IRQ number directly 2019-08-05 16:50:08 +01:00
st_magn_i2c.c iio: make st_sensors drivers use regmap 2019-07-27 22:52:06 +01:00
st_magn_spi.c iio: move 3-wire spi initialization to st_sensors_spi 2019-07-27 22:52:06 +01:00