lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20250901-icm42pmreg-v3-0-ef1336246960@geanix.com>
Date: Mon, 01 Sep 2025 09:49:12 +0200
From: Sean Nyekjaer <sean@...nix.com>
To: Jean-Baptiste Maneyrol <jean-baptiste.maneyrol@....com>, 
 rafael@...nel.org, Jonathan Cameron <jic23@...nel.org>, 
 David Lechner <dlechner@...libre.com>, 
 Nuno Sá <nuno.sa@...log.com>, 
 Andy Shevchenko <andy@...nel.org>
Cc: linux-iio@...r.kernel.org, linux-kernel@...r.kernel.org, 
 linux-pm@...r.kernel.org, Jean-Baptiste Maneyrol <jmaneyrol@...ensense.com>, 
 Jonathan Cameron <Jonathan.Cameron@...wei.com>, 
 Sean Nyekjaer <sean@...nix.com>
Subject: [PATCH v3 0/5] iio: imu: inv_icm42600: pm_runtime fixes + various
 changes

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.

@Rafael:
Is checking pm_runtime_status_suspended() is a viable option?
To avoid calling regulator_disable 2x during remove()?

Signed-off-by: Sean Nyekjaer <sean@...nix.com>
---
Changes in v3:
- Return early if pm_runtime_status_suspended() is set.
- Fixed various comments from Andy in "use guard() to release mutexes" 
- Link to v2: https://lore.kernel.org/r/20250808-icm42pmreg-v2-0-a480279e7721@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  |  25 ++---
 drivers/iio/imu/inv_icm42600/inv_icm42600_buffer.c |  27 +++--
 drivers/iio/imu/inv_icm42600/inv_icm42600_core.c   | 119 +++++++--------------
 drivers/iio/imu/inv_icm42600/inv_icm42600_gyro.c   |  20 ++--
 5 files changed, 67 insertions(+), 125 deletions(-)
---
base-commit: dfbbee0907fb30a1dd31ff1a84e1bd34bd824369
change-id: 20250708-icm42pmreg-24d824d978c4

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


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ