From: Kamal Wadhwa <kamal.wadhwa@oss.qualcomm.com>
To: Mark Brown <broonie@kernel.org>
Cc: Bjorn Andersson <andersson@kernel.org>,
Konrad Dybcio <konradybcio@kernel.org>,
Liam Girdwood <lgirdwood@gmail.com>,
Vinod Koul <vkoul@kernel.org>,
linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4 3/4] regulator: qcom-rpmh: readback voltage/bypass/mode/status set during bootup
Date: Wed, 1 Jul 2026 03:36:47 +0530 [thread overview]
Message-ID: <x7bfmqz3xq3sglwypqg5qyegb5mh3yaqvqv4dsitjtbemslj3s@dokc74swe26l> (raw)
In-Reply-To: <afE_iAU9xdIzHA9x@sirena.co.uk>
On Wed, Apr 29, 2026 at 08:15:20AM +0900, Mark Brown wrote:
> On Wed, Apr 29, 2026 at 03:03:31AM +0530, Kamal Wadhwa wrote:
>
> > To elaborate, till now for all chipsets using RPMH regulator driver, the boot
> > time voltage setting would always be overwritten by `min-microvolts` by the
> > framework. However, i found during the development of this patch that on some
> > chipsets like SM8550, SM8660 etc for one or two rails there exists some
> > misalignments between the bootloader voltage setting and the APPS side min/max
> > voltage limits(subset of RPMH firmware min/max) where the voltage value is
> > set lower or higher from the bootloader side compared to the DT min/max, which
> > caused the regulator registeration failure and all the sibling regulators under
> > the same pmic will also fail to register, even though issue was with only one
> > regulator.
>
> Why would this cause registration failures? Bringing the voltage in
> line with the constraints is a perfectly normal and fairly widely used
> operation.
(Very sorry for coming back late on this)
I looked up for some examples of the regulator probe failures i faced during
development of this patch.
It seems that regulator registration failures happen after adding the read
support ONLY if both of the conditions below are true for any regulator.
1. The [min or max]-microvolts values defined in the device tree didn’t
exactly match with any of the selector voltages supported by the
regulator.
2. On top of this, if the initial value read is out-of-range of the
DT min,max limit.
eg-
For board file(s) /arch/arm64/boot/dts/qcom/sm8550-*.dts, I found
that the voltage set during the boot stage for `vreg_l6n_3p3`
was 3312mV, which didn't match with the max-microvolts of `3304mV`
(which is the max enforced from RPMH firmware) and when i added this new
patch the regulator registration for L6N failed, and caused the probe to
fail.
Note - This we had fixed by reducing the regulator min-microvolts to 3200mV.
But since these error is getting unmasked only if we added get_voltage_sel()
support, so wanted to check if its ok to print these as errors, and do not
report voltage values out of [min, max] range and avoid the regulator
registration failures?
pleae note that, currently if one regulator registration fails, driver
will not register any other regulator and probe will exit with failure.
Debugging such issues will be simplified if we can know where the mismatch
happened with the error logs, and not have to do repeat testing multiple
times to fix (one-by-one) the firmware side mismatch between the boot and
rpmh firmware voltage values.
Regards,
Kamal
next prev parent reply other threads:[~2026-06-30 22:06 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-20 15:43 [PATCH v4 0/4] regulator: qcom-rpmh: Support RPMH address reads and use it for rpmh-regulators Kamal Wadhwa
2026-04-20 15:43 ` [PATCH v4 1/4] soc: qcom: rpmh: Add support to read back resource settings Kamal Wadhwa
2026-04-20 15:43 ` [PATCH v4 2/4] regulator: qcom-rpmh: Fix PMIC5 BOB bypass mode handling Kamal Wadhwa
2026-04-20 15:43 ` [PATCH v4 3/4] regulator: qcom-rpmh: readback voltage/bypass/mode/status set during bootup Kamal Wadhwa
2026-04-21 21:16 ` Mark Brown
2026-04-28 21:33 ` Kamal Wadhwa
2026-04-28 23:15 ` Mark Brown
2026-06-30 22:06 ` Kamal Wadhwa [this message]
2026-07-01 12:10 ` Mark Brown
2026-04-22 10:54 ` Konrad Dybcio
2026-04-23 9:28 ` Kamal Wadhwa
2026-04-20 15:43 ` [PATCH v4 4/4] regulator: qcom-rpmh: Fix coding style issues Kamal Wadhwa
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=x7bfmqz3xq3sglwypqg5qyegb5mh3yaqvqv4dsitjtbemslj3s@dokc74swe26l \
--to=kamal.wadhwa@oss.qualcomm.com \
--cc=andersson@kernel.org \
--cc=broonie@kernel.org \
--cc=konradybcio@kernel.org \
--cc=lgirdwood@gmail.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=vkoul@kernel.org \
/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