Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 89032da7 authored by Osvaldo Banuelos's avatar Osvaldo Banuelos
Browse files

regulator: cpr3-regulator: fix bug in LDO/BHS transition Vref selection



When switching a cluster from LDO to BHS or BHS to LDO mode,
the LDO Vref setpoint programmed before the regulator mode switch
should correspond to the VDD supply minus LDO headroom voltage.
However, there is a corner case which results in the violation
of this requirement. If an APM crossing occurs as a result of
switching the CPR corner, then the VDD supply is explicitly set
to the APM threshold voltage. If in addition, the VDD voltage is
being decreased, then the VDD voltage existing prior to the APM
switch is incorrectly used to determine the LDO Vref setpoint
requested before switching to BHS or LDO mode. Fix this by passing
the APM threshold voltage to cpr3_regulator_config_ldo() when
VDD voltage is decreasing and an APM switch took place beforehand.

Change-Id: I83a7e6eec17a92ecd4119d1a29791c50585a574c
Signed-off-by: default avatarOsvaldo Banuelos <osvaldob@codeaurora.org>
parent 09deb55f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment