Skip to content

Commit

Permalink
regulator: Add empty devm_regulator_bulk_get for !CONFIG_REGULATOR
Browse files Browse the repository at this point in the history
This fixes below build error if CONFIG_REGULATOR is disabled.

  CC      sound/soc/codecs/wm5100.o
sound/soc/codecs/wm5100.c: In function ‘wm5100_i2c_probe’:
sound/soc/codecs/wm5100.c:2462: error: implicit declaration of function ‘devm_regulator_bulk_get’
make[3]: *** [sound/soc/codecs/wm5100.o] Error 1
make[2]: *** [sound/soc/codecs] Error 2
make[1]: *** [sound/soc] Error 2
make: *** [sound] Error 2

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
  • Loading branch information
Axel Lin authored and Mark Brown committed Jan 27, 2012
1 parent e6e7403 commit e24abd6
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions include/linux/regulator/consumer.h
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,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)
{
Expand Down

0 comments on commit e24abd6

Please sign in to comment.