Skip to content

power: regulator: pfuze100: Fix voltage calculation and support high-range

Michael Trimarchi u-boot 2 versions In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest2 patches 4 repliesIn review
  2. v12 patches 0 repliesSuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/2power: regulator: pfuze100: support high voltage range bitdrivers/power/regulator/pfuze100.c+47 -180 replies
2/2power: regulator: pfuze100: Decouple hardware base voltage from DTS constraintsdrivers/power/regulator/pfuze100.c+51 -430 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH V2 0/2] power: regulator: pfuze100: Fix voltage calculation and support high-range

This series addresses two significant issues in the pfuze100 regulator driver regarding voltage calculation accuracy.

The first patch fixes the handling of the "high range" bit. PFUZE chips support two voltage ranges (controlled by a register bit) with different step sizes and base voltages. Previously, the driver assumed the low range, leading to incorrect voltage settings on boards configured for the high range.

The second patch corrects the interpretation of min_uV. The driver was incorrectly using the device tree's regulator-min-microvolt constraint as the mathematical base (zero-index) for voltage calculations. This caused offset errors whenever the DTS constraint differed from the hardware's absolute minimum. The patch introduces physical minimums in the driver descriptors to ensure calculations are based on the datasheet specifications, treating the DTS value strictly as a safety constraint.

Together, these changes align the U-Boot driver logic with the Linux kernel implementation and ensure correct voltage output.

Michael Trimarchi (2):
power: regulator: pfuze100: support high voltage range bit
power: regulator: pfuze100: Decouple hardware base voltage from DTS
constraints

 drivers/power/regulator/pfuze100.c | 138 ++++++++++++++++++-----------
 1 file changed, 88 insertions(+), 50 deletions(-)
Signature · 1 line
2.51.0