summaryrefslogtreecommitdiff
path: root/drivers/regulator/rohm-regulator.c
diff options
context:
space:
mode:
authorMatti Vaittinen <matti.vaittinen@fi.rohmeurope.com>2021-04-05 14:43:44 +0300
committerLee Jones <lee.jones@linaro.org>2021-04-14 10:19:48 +0100
commit80a71170646df80914a7290a197aca1e6116a49d (patch)
treeb7839b66890473dbc628a752c2848d5b5bdfd94f /drivers/regulator/rohm-regulator.c
parent9cf37cec4b7d2cb972ba1682dd5c8f39a5761129 (diff)
regulator: rohm-regulator: Support SNVS HW state.
The ROHM BD71815 supports setting voltage levels/regulator status for HW-states "RUN", "SUSPEND", "LPSR" and "SNVS". Add DT parsing helper also for SNVS state. Signed-off-by: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com> Acked-by: Mark Brown <broonie@kernel.org> Signed-off-by: Lee Jones <lee.jones@linaro.org>
Diffstat (limited to 'drivers/regulator/rohm-regulator.c')
-rw-r--r--drivers/regulator/rohm-regulator.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/regulator/rohm-regulator.c b/drivers/regulator/rohm-regulator.c
index 63aabb8c7786..6e0d9c08ec1c 100644
--- a/drivers/regulator/rohm-regulator.c
+++ b/drivers/regulator/rohm-regulator.c
@@ -95,6 +95,12 @@ int rohm_regulator_set_dvs_levels(const struct rohm_dvs_config *dvs,
mask = dvs->lpsr_mask;
omask = dvs->lpsr_on_mask;
break;
+ case ROHM_DVS_LEVEL_SNVS:
+ prop = "rohm,dvs-snvs-voltage";
+ reg = dvs->snvs_reg;
+ mask = dvs->snvs_mask;
+ omask = dvs->snvs_on_mask;
+ break;
default:
return -EINVAL;
}