iio: accel: bmi088: Balance runtime pm + use pm_runtime_resume_and_get()
authorJonathan Cameron <Jonathan.Cameron@huawei.com>
Sun, 9 May 2021 11:33:38 +0000 (12:33 +0100)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Mon, 17 May 2021 12:54:27 +0000 (13:54 +0100)
commit9a20795c60276e66f57ee7ecf88d124b1f769fcf
tree4905226f2dfc0bcca44f10f5ce7cc34e759308c0
parentf30172723ce270d6d60ac03748a6cbacc35b8f84
iio: accel: bmi088: Balance runtime pm + use pm_runtime_resume_and_get()

The call to pm_runtime_put_noidle() in remove() is not balanced by a get so
drop it.

Using pm_runtime_resume_and_get() allows for simple introduction of
error handling to allow for runtime resume failing.

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Cc: Mike Looijmans <mike.looijmans@topic.nl>
Reviewed-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
Link: https://lore.kernel.org/r/20210509113354.660190-13-jic23@kernel.org
drivers/iio/accel/bmi088-accel-core.c