From: Sanman Pradhan <sanman.p211993@gmail.com>
To: Guenter Roeck <linux@roeck-us.net>
Cc: linux-hwmon@vger.kernel.org, linux-kernel@vger.kernel.org,
Sanman Pradhan <psanman@juniper.net>
Subject: [PATCH v3 0/2] hwmon: (pmbus/max31785) refactor inter-access delay handling
Date: Wed, 18 Mar 2026 12:06:41 -0700 [thread overview]
Message-ID: <20260318190643.54372-1-psanman@juniper.net> (raw)
This v3 series addresses the feedback regarding the timing handover
between driver-local pre-probe accesses and the PMBus core's timing
management.
By exporting the PMBus core timing helpers and integrating them into
the MAX31785 driver, we can eliminate over 100 lines of local wrapper
boilerplate while ensuring that both standard and raw I2C transfers
respect the device's 250us inter-access delay requirement.
Changes in v3:
- Dropped the u16 -> u8 wrapper type fix in max31785.c as it was
already applied upstream.
- Fixed a comment style nit in max31785_read_long_data().
- Added an explicit max31785_wait() before pmbus_do_probe() to ensure
the 250us delay is respected during the handover from driver-local
timing to PMBus core timing.
Changes in v2:
- Dropped the i2c_smbus_write_byte_data() wrapper cleanup (applied upstream).
- Patch 1 (New): Export pmbus_wait() and pmbus_update_ts() from the PMBus
core, and move PMBUS_OP_* macros to drivers/hwmon/pmbus/pmbus.h.
- Patch 2: Replaced the usleep_range() sandwich around the raw long-read
path with the newly exported core timing functions. Placed
pmbus_update_ts() before the error check to ensure the core accurately
tracks the bus transaction even on failure.
Sanman Pradhan (2):
hwmon: (pmbus) export pmbus_wait and pmbus_update_ts
hwmon: (pmbus/max31785) use access_delay for PMBus-mediated accesses
drivers/hwmon/pmbus/max31785.c | 182 ++++++++++---------------------
drivers/hwmon/pmbus/pmbus.h | 9 ++
drivers/hwmon/pmbus/pmbus_core.c | 13 +--
3 files changed, 68 insertions(+), 136 deletions(-)
--
2.34.1
next reply other threads:[~2026-03-18 19:07 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-18 19:06 Sanman Pradhan [this message]
2026-03-18 19:06 ` [PATCH v3 1/2] hwmon: (pmbus) export pmbus_wait and pmbus_update_ts Sanman Pradhan
2026-03-18 20:49 ` Guenter Roeck
2026-03-18 19:06 ` [PATCH v3 2/2] hwmon: (pmbus/max31785) use access_delay for PMBus-mediated accesses Sanman Pradhan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260318190643.54372-1-psanman@juniper.net \
--to=sanman.p211993@gmail.com \
--cc=linux-hwmon@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=psanman@juniper.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox