Unified · Split
| @@ -13,6 +13,8 @@ · 12 unmodified lines | |||
| 13 | #include <linux/regulator/driver.h> | 13 | #include <linux/regulator/driver.h> |
| 14 | #include <linux/module.h> | 14 | #include <linux/module.h> |
| 15 | 15 | ||
| 16 | #include "internal.h" | ||
| 17 | |||
| 16 | /** | 18 | /** |
| 17 | * regulator_is_enabled_regmap - standard is_enabled() for regmap users | 19 | * regulator_is_enabled_regmap - standard is_enabled() for regmap users |
| 18 | * | 20 | * |
| @@ -881,3 +883,15 @@ void regulator_bulk_set_supply_names(struct regulator_bulk_data *consumers, · 862 unmodified lines | |||
| 881 | consumers[i].supply = supply_names[i]; | 883 | consumers[i].supply = supply_names[i]; |
| 882 | } | 884 | } |
| 883 | EXPORT_SYMBOL_GPL(regulator_bulk_set_supply_names); | 885 | EXPORT_SYMBOL_GPL(regulator_bulk_set_supply_names); |
| 886 | |||
| 887 | /** | ||
| 888 | * regulator_is_equal - test whether two regulators are the same | ||
| 889 | * | ||
| 890 | * @reg1: first regulator to operate on | ||
| 891 | * @reg2: second regulator to operate on | ||
| 892 | */ | ||
| 893 | bool regulator_is_equal(struct regulator *reg1, struct regulator *reg2) | ||
| 894 | { | ||
| 895 | return reg1->rdev == reg2->rdev; | ||
| 896 | } | ||
| 897 | EXPORT_SYMBOL_GPL(regulator_is_equal); | ||
| @@ -287,6 +287,8 @@ void regulator_bulk_set_supply_names(struct regulator_bulk_data *consumers, · 286 unmodified lines | |||
| 287 | const char *const *supply_names, | 287 | const char *const *supply_names, |
| 288 | unsigned int num_supplies); | 288 | unsigned int num_supplies); |
| 289 | 289 | ||
| 290 | bool regulator_is_equal(struct regulator *reg1, struct regulator *reg2); | ||
| 291 | |||
| 290 | #else | 292 | #else |
| 291 | 293 | ||
| 292 | /* | 294 | /* |
| @@ -593,6 +595,11 @@ regulator_bulk_set_supply_names(struct regulator_bulk_data *consumers, · 300 unmodified lines | |||
| 593 | { | 595 | { |
| 594 | } | 596 | } |
| 595 | 597 | ||
| 598 | static inline bool | ||
| 599 | regulator_is_equal(struct regulator *reg1, struct regulator *reg2) | ||
| 600 | { | ||
| 601 | return false; | ||
| 602 | } | ||
| 596 | #endif | 603 | #endif |
| 597 | 604 | ||
| 598 | static inline int regulator_set_voltage_triplet(struct regulator *regulator, | 605 | static inline int regulator_set_voltage_triplet(struct regulator *regulator, |