summaryrefslogtreecommitdiff
path: root/drivers/leds/leds-gpio.c
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2022-09-02 17:55:25 -0700
committerBartosz Golaszewski <bartosz.golaszewski@linaro.org>2022-11-09 13:59:21 +0100
commita055204b063ade914e6dd6e270d3c2c0453a3cf5 (patch)
tree690cf2a435cfd26336133da0eeede5eb87c26a8c /drivers/leds/leds-gpio.c
parent80280df758c1498485988b30cf6887fde7796056 (diff)
leds: gpio: switch to using devm_fwnode_gpiod_get()
devm_fwnode_get_gpiod_from_child() is going away as the name is too unwieldy, let's switch to using the new devm_fwnode_gpiod_get(). Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Diffstat (limited to 'drivers/leds/leds-gpio.c')
-rw-r--r--drivers/leds/leds-gpio.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/leds/leds-gpio.c b/drivers/leds/leds-gpio.c
index 092eb59a7d32..ce4e79939731 100644
--- a/drivers/leds/leds-gpio.c
+++ b/drivers/leds/leds-gpio.c
@@ -151,9 +151,8 @@ static struct gpio_leds_priv *gpio_leds_create(struct platform_device *pdev)
* will be updated after LED class device is registered,
* Only then the final LED name is known.
*/
- led.gpiod = devm_fwnode_get_gpiod_from_child(dev, NULL, child,
- GPIOD_ASIS,
- NULL);
+ led.gpiod = devm_fwnode_gpiod_get(dev, child, NULL, GPIOD_ASIS,
+ NULL);
if (IS_ERR(led.gpiod)) {
fwnode_handle_put(child);
return ERR_CAST(led.gpiod);