]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
regulator: s2mps11: refactor S2MPG10 ::set_voltage_time() for S2MPG11 reuse
authorAndré Draszik <andre.draszik@linaro.org>
Thu, 22 Jan 2026 15:43:44 +0000 (15:43 +0000)
committerMark Brown <broonie@kernel.org>
Wed, 4 Feb 2026 13:35:38 +0000 (13:35 +0000)
commit8f23cfbe4463c3de2e552aed106e179c0c932b6e
tree1b14264da744a62202384241595eff904bbace39
parenta2b8b9f33ce30ab51b33b52dc52e55d6930b9a02
regulator: s2mps11: refactor S2MPG10 ::set_voltage_time() for S2MPG11 reuse

The upcoming S2MPG11 support needs a similar, but different version of
::set_voltage_time(). For S2MPG10, the downwards and upwards ramps for
a rail are at different offsets at the same bit positions, while for
S2MPG11 the ramps are at the same offset at different bit positions.

Refactor the existing version slightly to allow reuse.

Signed-off-by: André Draszik <andre.draszik@linaro.org>
Link: https://patch.msgid.link/20260122-s2mpg1x-regulators-v7-17-3b1f9831fffd@linaro.org
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/regulator/s2mps11.c