From: Mark Brown Date: Mon, 7 May 2012 17:18:45 +0000 (+0100) Subject: regulator: wm8994: Convert to gpio_request_one() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=09e3fd202df67ec5d6d9a04c05b58c7367580226;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git regulator: wm8994: Convert to gpio_request_one() Signed-off-by: Mark Brown --- diff --git a/drivers/regulator/wm8994-regulator.c b/drivers/regulator/wm8994-regulator.c index 0ee81e1b6463..1f7f43cfc2d1 100644 --- a/drivers/regulator/wm8994-regulator.c +++ b/drivers/regulator/wm8994-regulator.c @@ -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;