diff options
author | Mark Brown | 2012-03-18 22:38:28 +0100 |
---|---|---|
committer | Mark Brown | 2012-03-18 22:38:28 +0100 |
commit | c02f935f5f646fe1b5dbcd909e9d09c3a912914e (patch) | |
tree | 8ee7e852c33aa37dae186c89d4a9ed518be4e5fb /include/linux | |
parent | Merge remote-tracking branch 'regulator/topic/stub' into regulator-next (diff) | |
parent | regulator: add devm_regulator_* to the list of managed interfaces (diff) | |
download | kernel-qcow2-linux-c02f935f5f646fe1b5dbcd909e9d09c3a912914e.tar.gz kernel-qcow2-linux-c02f935f5f646fe1b5dbcd909e9d09c3a912914e.tar.xz kernel-qcow2-linux-c02f935f5f646fe1b5dbcd909e9d09c3a912914e.zip |
Merge remote-tracking branches 'regulator/topic/devm' and 'regulator/topic/stub' into regulator-next
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/regulator/consumer.h | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/include/linux/regulator/consumer.h b/include/linux/regulator/consumer.h index f2698a0edfc4..b6c8d717c7ec 100644 --- a/include/linux/regulator/consumer.h +++ b/include/linux/regulator/consumer.h @@ -132,9 +132,12 @@ struct regulator_bulk_data { /* regulator get and put */ struct regulator *__must_check regulator_get(struct device *dev, const char *id); +struct regulator *__must_check devm_regulator_get(struct device *dev, + const char *id); struct regulator *__must_check regulator_get_exclusive(struct device *dev, const char *id); void regulator_put(struct regulator *regulator); +void devm_regulator_put(struct regulator *regulator); /* regulator output control and status */ int regulator_enable(struct regulator *regulator); @@ -145,6 +148,8 @@ int regulator_disable_deferred(struct regulator *regulator, int ms); int regulator_bulk_get(struct device *dev, int num_consumers, struct regulator_bulk_data *consumers); +int devm_regulator_bulk_get(struct device *dev, int num_consumers, + struct regulator_bulk_data *consumers); int regulator_bulk_enable(int num_consumers, struct regulator_bulk_data *consumers); int regulator_bulk_disable(int num_consumers, @@ -200,10 +205,21 @@ static inline struct regulator *__must_check regulator_get(struct device *dev, */ return NULL; } + +static inline struct regulator *__must_check +devm_regulator_get(struct device *dev, const char *id) +{ + return NULL; +} + static inline void regulator_put(struct regulator *regulator) { } +static inline void devm_regulator_put(struct regulator *regulator) +{ +} + static inline int regulator_enable(struct regulator *regulator) { return 0; @@ -237,6 +253,12 @@ static inline int regulator_bulk_get(struct device *dev, return 0; } +static inline int devm_regulator_bulk_get(struct device *dev, int num_consumers, + struct regulator_bulk_data *consumers) +{ + return 0; +} + static inline int regulator_bulk_enable(int num_consumers, struct regulator_bulk_data *consumers) { |