diff options
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-06-11 20:14:24 +0800 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2012-06-18 13:39:59 +0100 |
commit | 08aed2f6fb09c9f8efc9258c152072ed614db226 (patch) | |
tree | 3a9a1487969fe10d56d9edfcc79a9cf1e94654ee /include/linux/regulator | |
parent | 230a5a1c41464f7fe5b676c21280ae4effa222c8 (diff) |
regulator: stubs: Make stub regulator_get_voltage() return an error
Returning 0 isn't useful, it's not even meaningful if there is a real
regulator there.
Reported-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'include/linux/regulator')
-rw-r--r-- | include/linux/regulator/consumer.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/regulator/consumer.h b/include/linux/regulator/consumer.h index 4ed1b30ac5fc..9ff29ef317c2 100644 --- a/include/linux/regulator/consumer.h +++ b/include/linux/regulator/consumer.h @@ -291,7 +291,7 @@ static inline int regulator_set_voltage(struct regulator *regulator, static inline int regulator_get_voltage(struct regulator *regulator) { - return 0; + return -EINVAL; } static inline int regulator_set_current_limit(struct regulator *regulator, |