mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-30 08:02:30 +00:00
regulator: wm8994: Convert to gpio_request_one()
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This commit is contained in:
parent
a60cfce051
commit
09e3fd202d
1 changed files with 1 additions and 8 deletions
|
@ -224,19 +224,12 @@ static __devinit int wm8994_ldo_probe(struct platform_device *pdev)
|
|||
if (pdata->ldo[id].enable && gpio_is_valid(pdata->ldo[id].enable)) {
|
||||
ldo->enable = pdata->ldo[id].enable;
|
||||
|
||||
ret = gpio_request(ldo->enable, "WM8994 LDO enable");
|
||||
ret = gpio_request_one(ldo->enable, 0, "WM8994 LDO enable");
|
||||
if (ret < 0) {
|
||||
dev_err(&pdev->dev, "Failed to get enable GPIO: %d\n",
|
||||
ret);
|
||||
goto err;
|
||||
}
|
||||
|
||||
ret = gpio_direction_output(ldo->enable, ldo->is_enabled);
|
||||
if (ret < 0) {
|
||||
dev_err(&pdev->dev, "Failed to set GPIO up: %d\n",
|
||||
ret);
|
||||
goto err_gpio;
|
||||
}
|
||||
} else
|
||||
ldo->is_enabled = true;
|
||||
|
||||
|
|
Loading…
Reference in a new issue