Re: [PATCH v5 3/4] regulator: qcom-rpmh: readback voltage/bypass/mode/status set during bootup

From: Mark Brown

Date: Wed Jul 22 2026 - 13:09:46 EST


On Mon, Jul 20, 2026 at 09:06:40PM +0530, Kamal Wadhwa wrote:

> Currently, during regulator registration, regulator framework sends an
> unnecessary `min-microvolts` request for the rpmh-regulator device. This
> happens because in current design, we do not have a way to readback the
> voltage settings that was set during the bootloader stage.

> +static int rpmh_regulator_vrm_get_status(struct regulator_dev *rdev)
> +{
> + struct rpmh_vreg *vreg = rdev_get_drvdata(rdev);
> +
> + return vreg->status;
> +}

A get_status() operation should be reading the actual hardware status
right now, not driver state - this should be reading whatever the value
is right now. If the hardware doesn't support this then just don't
provide the operation.

Attachment: signature.asc
Description: PGP signature