]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
iio: imu: inv_icm45600: fix regulator put warning when probe fails
authorJean-Baptiste Maneyrol <jean-baptiste.maneyrol@tdk.com>
Tue, 17 Feb 2026 10:44:50 +0000 (11:44 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 19 Mar 2026 15:15:30 +0000 (16:15 +0100)
commitacce8ebc5e63cfbe85d1490ba3da4b7c39cb2796
tree30081bdfb77e73f9a3ad1c4b9fe789aec8dc4c1e
parent2280e5fa27b719b8299031313358d8d414f4ce3e
iio: imu: inv_icm45600: fix regulator put warning when probe fails

commit 2617595538be8a2f270ad13fccb9f56007b292d7 upstream.

When the driver probe fails we encounter a regulator put warning
because vddio regulator is not stopped before release. The issue
comes from pm_runtime not already setup when core probe fails and
the vddio regulator disable callback is called.

Fix the issue by setting pm_runtime active early before vddio
regulator resource cleanup. This requires to cut pm_runtime
set_active and enable in 2 function calls.

Fixes: 7ff021a3faca ("iio: imu: inv_icm45600: add new inv_icm45600 driver")
Signed-off-by: Jean-Baptiste Maneyrol <jean-baptiste.maneyrol@tdk.com>
Cc: stable@vger.kernel.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/iio/imu/inv_icm45600/inv_icm45600_core.c