diff options
author | Finley Xiao <finley.xiao@rock-chips.com> | 2018-04-18 10:01:01 +0800 |
---|---|---|
committer | Tao Huang <huangtao@rock-chips.com> | 2018-04-18 17:22:03 +0800 |
commit | 6882654464ae472b97216a631019fc4b04873ac1 (patch) | |
tree | f969c9aa0deb859d254852671d4f102598aedb0d /include | |
parent | 859175c09320faf4b4c52ef8da7d6649b9758119 (diff) |
regulator: core: Add support to limit min_uV during system startup
Now a regulator device can supply multiple consumers at the same time,
if a consumer starts and set a low voltage, another consumer doesn't
start in kernel but has been set a high frequency in bootloader will
abort.
This patch Adds support to limit min_uV during kernel startup to make
sure the voltage can suit the needs of all consumers.
Change-Id: Ibd16a8e44916798021e2470c90a8e3488df206f4
Signed-off-by: Finley Xiao <finley.xiao@rock-chips.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/regulator/machine.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/regulator/machine.h b/include/linux/regulator/machine.h index 8ab67b6f0250..07e913c791aa 100644 --- a/include/linux/regulator/machine.h +++ b/include/linux/regulator/machine.h @@ -80,6 +80,9 @@ struct regulator_state { * @uV_offset: Offset applied to voltages from consumer to compensate for * voltage drops. * + * @early_min_uV: Minimum voltage during system startup, make sure we select + * a voltage that suits the needs of all regulator consumers. + * * @min_uA: Smallest current consumers may set. * @max_uA: Largest current consumers may set. * @ilim_uA: Maximum input current. @@ -126,6 +129,9 @@ struct regulation_constraints { int min_uV; int max_uV; + /* Minimum voltage during system startup */ + int early_min_uV; + int uV_offset; /* current output range (inclusive) - for current control */ |