summaryrefslogtreecommitdiffstats
path: root/kernel/include/linux/regulator/consumer.h
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/include/linux/regulator/consumer.h')
-rw-r--r--kernel/include/linux/regulator/consumer.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/kernel/include/linux/regulator/consumer.h b/kernel/include/linux/regulator/consumer.h
index f8a689ed6..9e0e76992 100644
--- a/kernel/include/linux/regulator/consumer.h
+++ b/kernel/include/linux/regulator/consumer.h
@@ -550,8 +550,24 @@ static inline int regulator_count_voltages(struct regulator *regulator)
{
return 0;
}
+
+static inline int regulator_list_voltage(struct regulator *regulator, unsigned selector)
+{
+ return -EINVAL;
+}
+
#endif
+static inline int regulator_set_voltage_triplet(struct regulator *regulator,
+ int min_uV, int target_uV,
+ int max_uV)
+{
+ if (regulator_set_voltage(regulator, target_uV, max_uV) == 0)
+ return 0;
+
+ return regulator_set_voltage(regulator, min_uV, max_uV);
+}
+
static inline int regulator_set_voltage_tol(struct regulator *regulator,
int new_uV, int tol_uV)
{