aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/regulator
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2012-03-18 17:38:28 -0400
committerMark Brown <broonie@opensource.wolfsonmicro.com>2012-03-18 17:38:28 -0400
commitc02f935f5f646fe1b5dbcd909e9d09c3a912914e (patch)
tree8ee7e852c33aa37dae186c89d4a9ed518be4e5fb /include/linux/regulator
parentc592c761a36286ab83451daa37a21c8558ea99c0 (diff)
parentc1432b1ebc684890ac81915695617ff4adfec357 (diff)
Merge remote-tracking branches 'regulator/topic/devm' and 'regulator/topic/stub' into regulator-next
Diffstat (limited to 'include/linux/regulator')
-rw-r--r--include/linux/regulator/consumer.h22
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 {
132/* regulator get and put */ 132/* regulator get and put */
133struct regulator *__must_check regulator_get(struct device *dev, 133struct regulator *__must_check regulator_get(struct device *dev,
134 const char *id); 134 const char *id);
135struct regulator *__must_check devm_regulator_get(struct device *dev,
136 const char *id);
135struct regulator *__must_check regulator_get_exclusive(struct device *dev, 137struct regulator *__must_check regulator_get_exclusive(struct device *dev,
136 const char *id); 138 const char *id);
137void regulator_put(struct regulator *regulator); 139void regulator_put(struct regulator *regulator);
140void devm_regulator_put(struct regulator *regulator);
138 141
139/* regulator output control and status */ 142/* regulator output control and status */
140int regulator_enable(struct regulator *regulator); 143int regulator_enable(struct regulator *regulator);
@@ -145,6 +148,8 @@ int regulator_disable_deferred(struct regulator *regulator, int ms);
145 148
146int regulator_bulk_get(struct device *dev, int num_consumers, 149int regulator_bulk_get(struct device *dev, int num_consumers,
147 struct regulator_bulk_data *consumers); 150 struct regulator_bulk_data *consumers);
151int devm_regulator_bulk_get(struct device *dev, int num_consumers,
152 struct regulator_bulk_data *consumers);
148int regulator_bulk_enable(int num_consumers, 153int regulator_bulk_enable(int num_consumers,
149 struct regulator_bulk_data *consumers); 154 struct regulator_bulk_data *consumers);
150int regulator_bulk_disable(int num_consumers, 155int regulator_bulk_disable(int num_consumers,
@@ -200,10 +205,21 @@ static inline struct regulator *__must_check regulator_get(struct device *dev,
200 */ 205 */
201 return NULL; 206 return NULL;
202} 207}
208
209static inline struct regulator *__must_check
210devm_regulator_get(struct device *dev, const char *id)
211{
212 return NULL;
213}
214
203static inline void regulator_put(struct regulator *regulator) 215static inline void regulator_put(struct regulator *regulator)
204{ 216{
205} 217}
206 218
219static inline void devm_regulator_put(struct regulator *regulator)
220{
221}
222
207static inline int regulator_enable(struct regulator *regulator) 223static inline int regulator_enable(struct regulator *regulator)
208{ 224{
209 return 0; 225 return 0;
@@ -237,6 +253,12 @@ static inline int regulator_bulk_get(struct device *dev,
237 return 0; 253 return 0;
238} 254}
239 255
256static inline int devm_regulator_bulk_get(struct device *dev, int num_consumers,
257 struct regulator_bulk_data *consumers)
258{
259 return 0;
260}
261
240static inline int regulator_bulk_enable(int num_consumers, 262static inline int regulator_bulk_enable(int num_consumers,
241 struct regulator_bulk_data *consumers) 263 struct regulator_bulk_data *consumers)
242{ 264{