diff options
author | Dmitry Osipenko <digetx@gmail.com> | 2019-06-24 00:08:32 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2019-06-25 12:15:35 +0100 |
commit | d22b85a1b97d12a4940ef9d778f6122546736f78 (patch) | |
tree | abbbb2a4c612028abb7e5d6e6c73ca7dcc9e4a40 /include/linux | |
parent | d8ca7d184b33af7913c244900df77c6cad6a5590 (diff) |
regulator: core: Expose some of core functions needed by couplers
Expose some of internal functions that are required for implementation of
customized regulator couplers.
Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/regulator/coupler.h | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/include/linux/regulator/coupler.h b/include/linux/regulator/coupler.h index 98dd1f74d605..0212d6255e4e 100644 --- a/include/linux/regulator/coupler.h +++ b/include/linux/regulator/coupler.h @@ -52,11 +52,46 @@ struct regulator_coupler { #ifdef CONFIG_REGULATOR int regulator_coupler_register(struct regulator_coupler *coupler); +const char *rdev_get_name(struct regulator_dev *rdev); +int regulator_check_consumers(struct regulator_dev *rdev, + int *min_uV, int *max_uV, + suspend_state_t state); +int regulator_check_voltage(struct regulator_dev *rdev, + int *min_uV, int *max_uV); +int regulator_get_voltage_rdev(struct regulator_dev *rdev); +int regulator_set_voltage_rdev(struct regulator_dev *rdev, + int min_uV, int max_uV, + suspend_state_t state); #else static inline int regulator_coupler_register(struct regulator_coupler *coupler) { return 0; } +static inline const char *rdev_get_name(struct regulator_dev *rdev) +{ + return NULL; +} +static inline int regulator_check_consumers(struct regulator_dev *rdev, + int *min_uV, int *max_uV, + suspend_state_t state) +{ + return -EINVAL; +} +static inline int regulator_check_voltage(struct regulator_dev *rdev, + int *min_uV, int *max_uV) +{ + return -EINVAL; +} +static inline int regulator_get_voltage_rdev(struct regulator_dev *rdev) +{ + return -EINVAL; +} +static inline int regulator_set_voltage_rdev(struct regulator_dev *rdev, + int min_uV, int max_uV, + suspend_state_t state) +{ + return -EINVAL; +} #endif #endif |