public inbox for linux-hwmon@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/5] hwmon: (pmbus) PMBus fixes and improvements
@ 2026-03-25 18:16 Guenter Roeck
  2026-03-25 18:16 ` [PATCH 1/5] hwmon: (pmbus) Mark lowest/average/highest/rated attributes as read-only Guenter Roeck
                   ` (5 more replies)
  0 siblings, 6 replies; 10+ messages in thread
From: Guenter Roeck @ 2026-03-25 18:16 UTC (permalink / raw)
  To: Hardware Monitoring; +Cc: Sanman Pradhan, Guenter Roeck

The first patch of the series marks lowest/average/highest/rated attributes
as read-only. Those are values provided by the chip and must not be
modified during runtime (if that is even supported by the chip).

The second patch adds support for write-only attributes. As it turned out,
reading the "reset_history" attributes returned random values. The code now
returns 0 when reading those attributes to avoid ABI hiccups.

The third patch adds locking for regulator operations to avoid interference
with other PMBus operations.

The last two patches introduce and start using guard() and scoped_guard()
for PMBus locking to simplify the code, especially for error handling.

Change log since RFT/RFC: All patches were tested with real hardware.

----------------------------------------------------------------
Guenter Roeck (5):
      hwmon: (pmbus) Mark lowest/average/highest/rated attributes as read-only
      hwmon: (pmbus) Introduce the concept of "write-only" attributes
      hwmon: (pmbus/core) Protect regulator operations with mutex
      hwmon: (pmbus) Add support for guarded PMBus lock
      hwmon: (pmbus_core) Use guard() for mutex protection

 drivers/hwmon/pmbus/pmbus.h      |   5 +
 drivers/hwmon/pmbus/pmbus_core.c | 373 +++++++++++++++++++++++----------------
 2 files changed, 222 insertions(+), 156 deletions(-)

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

end of thread, other threads:[~2026-03-25 20:31 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-25 18:16 [PATCH 0/5] hwmon: (pmbus) PMBus fixes and improvements Guenter Roeck
2026-03-25 18:16 ` [PATCH 1/5] hwmon: (pmbus) Mark lowest/average/highest/rated attributes as read-only Guenter Roeck
2026-03-25 18:16 ` [PATCH 2/5] hwmon: (pmbus) Introduce the concept of "write-only" attributes Guenter Roeck
2026-03-25 18:16 ` [PATCH 3/5] hwmon: (pmbus/core) Protect regulator operations with mutex Guenter Roeck
2026-03-25 19:05   ` Pradhan, Sanman
2026-03-25 20:02     ` Guenter Roeck
2026-03-25 18:16 ` [PATCH 4/5] hwmon: (pmbus) Add support for guarded PMBus lock Guenter Roeck
2026-03-25 18:16 ` [PATCH 5/5] hwmon: (pmbus_core) Use guard() for mutex protection Guenter Roeck
2026-03-25 20:25 ` [PATCH 0/5] hwmon: (pmbus) PMBus fixes and improvements Pradhan, Sanman
2026-03-25 20:31   ` Guenter Roeck

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox