Skip to content

Commit

Permalink
regulator: Use _cansleep() for WM8994 regulator GPIOs
Browse files Browse the repository at this point in the history
The WM8994 regulator driver is perfectly happy if the GPIO used to enable
the regulator sleeps so call the appropriate GPIO API.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
  • Loading branch information
Mark Brown authored and Liam Girdwood committed May 30, 2011
1 parent f21e0e8 commit 2ae3636
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/regulator/wm8994-regulator.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ static int wm8994_ldo_enable(struct regulator_dev *rdev)
if (!ldo->enable)
return 0;

gpio_set_value(ldo->enable, 1);
gpio_set_value_cansleep(ldo->enable, 1);
ldo->is_enabled = true;

return 0;
Expand All @@ -57,7 +57,7 @@ static int wm8994_ldo_disable(struct regulator_dev *rdev)
if (!ldo->enable)
return -EINVAL;

gpio_set_value(ldo->enable, 0);
gpio_set_value_cansleep(ldo->enable, 0);
ldo->is_enabled = false;

return 0;
Expand Down

0 comments on commit 2ae3636

Please sign in to comment.