linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/5] iio: imu: inv_icm42600: pm_runtime fixes + various changes
@ 2025-08-08 15:57 Sean Nyekjaer
  2025-08-08 15:57 ` [PATCH v2 1/5] iio: imu: inv_icm42600: Simplify pm_runtime setup Sean Nyekjaer
                   ` (4 more replies)
  0 siblings, 5 replies; 15+ messages in thread
From: Sean Nyekjaer @ 2025-08-08 15:57 UTC (permalink / raw)
  To: Jean-Baptiste Maneyrol, Jonathan Cameron, David Lechner,
	Nuno Sá, Andy Shevchenko
  Cc: linux-iio, linux-kernel, Jean-Baptiste Maneyrol, Jonathan Cameron,
	Sean Nyekjaer

This series was triggered by "Runtime PM usage count underflow!" when
unloading the module(s).
By testing the driver in various use cases and reading code it was
obvious that it could need some tiding up.

I'm still not 100% satisfied with suspend/resume is calling directly to
vddio_enable/disable. In my mind it should be managed by pm_runtime.

Signed-off-by: Sean Nyekjaer <sean@geanix.com>
---
Changes in v2:
- Removed patch iio: imu: inv_icm42600: Use inv_icm42600_disable_vddio_reg()
- Moved changes from patch iio: imu: inv_icm42600: Remove redundant
  error msg on regulator_disable() into iio: imu: inv_icm42600: Simplify
  pm_runtime setup.
- Move associated sleep close to enabling of vdd
- Pass regulator as the parameter to inv_icm42600_disable_vddio_reg()
- Use devm_pm_runtime_set_active_enabled() to simplify even more
- Added a new commit that uses guard() to release mutexes
- Link to v1: https://lore.kernel.org/r/20250709-icm42pmreg-v1-0-3d0e793c99b2@geanix.com

---
Sean Nyekjaer (5):
      iio: imu: inv_icm42600: Simplify pm_runtime setup
      iio: imu: inv_icm42600: Drop redundant pm_runtime reinitialization in resume
      iio: imu: inv_icm42600: Avoid configuring if already pm_runtime suspended
      iio: imu: inv_icm42600: Use devm_regulator_get_enable() for vdd regulator
      iio: imu: inv_icm42600: use guard() to release mutexes

 drivers/iio/imu/inv_icm42600/inv_icm42600.h        |   1 -
 drivers/iio/imu/inv_icm42600/inv_icm42600_accel.c  |  11 +--
 drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c |  27 +++---
 drivers/iio/imu/inv_icm42600/inv_icm42600_core.c   | 105 +++++++--------------
 drivers/iio/imu/inv_icm42600/inv_icm42600_gyro.c   |  11 +--
 5 files changed, 51 insertions(+), 104 deletions(-)
---
base-commit: a5651af7f531ca57b9fc3114de77d9050012eb8d
change-id: 20250708-icm42pmreg-24d824d978c4

Best regards,
-- 
Sean Nyekjaer <sean@geanix.com>


^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2025-08-30 14:46 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-08 15:57 [PATCH v2 0/5] iio: imu: inv_icm42600: pm_runtime fixes + various changes Sean Nyekjaer
2025-08-08 15:57 ` [PATCH v2 1/5] iio: imu: inv_icm42600: Simplify pm_runtime setup Sean Nyekjaer
2025-08-08 21:37   ` Andy Shevchenko
2025-08-09 18:06     ` Jonathan Cameron
2025-08-09 20:27       ` Andy Shevchenko
2025-08-11 14:21         ` Sean Nyekjaer
2025-08-11 14:24           ` Andy Shevchenko
2025-08-25 15:14           ` Sean Nyekjaer
2025-08-30 14:45             ` Jonathan Cameron
2025-08-08 15:57 ` [PATCH v2 2/5] iio: imu: inv_icm42600: Drop redundant pm_runtime reinitialization in resume Sean Nyekjaer
2025-08-08 15:57 ` [PATCH v2 3/5] iio: imu: inv_icm42600: Avoid configuring if already pm_runtime suspended Sean Nyekjaer
2025-08-08 15:57 ` [PATCH v2 4/5] iio: imu: inv_icm42600: Use devm_regulator_get_enable() for vdd regulator Sean Nyekjaer
2025-08-08 15:57 ` [PATCH v2 5/5] iio: imu: inv_icm42600: use guard() to release mutexes Sean Nyekjaer
2025-08-08 21:52   ` Andy Shevchenko
2025-08-11 11:47     ` Sean Nyekjaer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).