]> git.baikalelectronics.ru Git - kernel.git/commit
regulator: Deprecate regulator_can_change_voltage()
authorMark Brown <broonie@kernel.org>
Wed, 30 Mar 2016 19:04:30 +0000 (12:04 -0700)
committerMark Brown <broonie@kernel.org>
Wed, 30 Mar 2016 19:09:41 +0000 (12:09 -0700)
commit8fa4031efab6d5bb5cec1d60fd596aa01b18e0d6
treecf4e179105b1a4b63fc3768c2a978ba199b23dac
parent3039f62d3fccb077513a4ffae4d1ef4609c1b724
regulator: Deprecate regulator_can_change_voltage()

All current users of regulator_can_change_voltage() are abusing it,
using it to wrap a call to regulator_set_voltage() on probe without any
alternative handling for fixed voltages.  Drivers should only be using
regulator_set_voltage() if they need to vary voltages at runtime, fixed
voltages should normally be set via machine constraints, and calling
regulator_set_voltage() on a regulator which can't be varied will
succeed if the current voltage is within the range requested so users
shouldn't worry if they have permission to vary normally.

Deprecate the API to try to stop any new users appearing while we fix
the current callers.

Signed-off-by: Mark Brown <broonie@kernel.org>
include/linux/regulator/consumer.h