leds: gpio: Fix semantic error
authorLinus Walleij <linus.walleij@linaro.org>
Fri, 3 Jul 2020 18:13:38 +0000 (20:13 +0200)
committerPavel Machek <pavel@ucw.cz>
Sun, 12 Jul 2020 08:14:05 +0000 (10:14 +0200)
commitc4e94413922b8d5dd251cffd732b349772d22973
treef152899a4d5850b376306ad2da87080fd0dd83ef
parent302a085c20194bfa7df52e0fe684ee0c41da02e6
leds: gpio: Fix semantic error

The leds-gpio driver mixes up the legacy GPIO flags with the
GPIO descriptor flags and passes a legacy flag to
devm_gpiod_get_index().

Fix this by replacing the flags variable with the strict
descriptor flag.

Fixes: 45d4c6de4e49 ("leds: gpio: Try to lookup gpiod from device")
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Pavel Machek <pavel@ucw.cz>
drivers/leds/leds-gpio.c