summaryrefslogtreecommitdiff
path: root/drivers/leds
diff options
context:
space:
mode:
authorOlliver Schinagl <oliver@schinagl.nl>2015-01-21 22:33:46 +0100
committerLinus Walleij <linus.walleij@linaro.org>2015-03-04 13:58:58 +0100
commit1feb57a245a4910b03202a814ffc51a900bd4aca (patch)
treeaa32b4a6ceb8132a7c89c4edae70ea83a7cbc1a0 /drivers/leds
parentb80eef95beb04760629822fa130aeed54cdfafca (diff)
gpio: add parameter to allow the use named gpios
The gpio binding document says that new code should always use named gpios. Patch 40b73183 added support to parse a list of gpios from child nodes, but does not make it possible to use named gpios. This patch adds the con_id property and implements it is done in gpiolib.c, where the old-style of using unnamed gpios still works. Signed-off-by: Olliver Schinagl <oliver@schinagl.nl> Acked-by: Bryan Wu <cooloney@gmail.com> Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Reviewed-by: Alexandre Courbot <acourbot@nvidia.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/leds')
-rw-r--r--drivers/leds/leds-gpio.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/leds/leds-gpio.c b/drivers/leds/leds-gpio.c
index d26af0a79a90..15eb3f86f670 100644
--- a/drivers/leds/leds-gpio.c
+++ b/drivers/leds/leds-gpio.c
@@ -184,7 +184,7 @@ static struct gpio_leds_priv *gpio_leds_create(struct platform_device *pdev)
struct gpio_led led = {};
const char *state = NULL;
- led.gpiod = devm_get_gpiod_from_child(dev, child);
+ led.gpiod = devm_get_gpiod_from_child(dev, NULL, child);
if (IS_ERR(led.gpiod)) {
fwnode_handle_put(child);
ret = PTR_ERR(led.gpiod);