aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/leds/leds-max8997.c (unfollow)
AgeCommit message (Collapse)AuthorFilesLines
2019-11-03leds: lm3692x: Handle failure to probe the regulatorGuido Günther1-2/+11
Instead use devm_regulator_get_optional since the regulator is optional and check for errors. Signed-off-by: Guido Günther <agx@sigxcpu.org> Acked-by: Pavel Machek <pavel@ucw.cz> Reviewed-by: Dan Murphy <dmurphy@ti.com> Signed-off-by: Pavel Machek <pavel@ucw.cz>
2019-11-03leds: lm3692x: Don't overwrite return value in error pathGuido Günther1-4/+5
The driver currently reports successful initialization on every failure as long as it's able to power off the regulator. Don't check the return value of regulator_disable to avoid that. Signed-off-by: Guido Günther <agx@sigxcpu.org> Acked-by: Pavel Machek <pavel@ucw.cz> Reviewed-by: Dan Murphy <dmurphy@ti.com> Signed-off-by: Pavel Machek <pavel@ucw.cz>
2019-11-03leds: lm3692x: Print error value on dev_errGuido Günther1-7/+10
This gives a way better idea what is going on. Signed-off-by: Guido Günther <agx@sigxcpu.org> Reviewed-by: Dan Murphy <dmurphy@ti.com> Acked-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Pavel Machek <pavel@ucw.cz>
2019-11-03leds: tlc591xx: use devm_led_classdev_register_ext()Jean-Jacques Hiblot1-3/+5
Use devm_led_classdev_register_ext() to pass the fwnode to the LED core. The fwnode can then be used by the firmware core to create meaningful names. Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com> Signed-off-by: Pavel Machek <pavel@ucw.cz>
2019-11-03leds: tlc591xx: simplify driver by using the managed led APIJean-Jacques Hiblot1-62/+22
Use the managed API of the LED class (devm_led_classdev_register() instead of led_classdev_register()). This allows us to remove the code used to track-and-destroy the LED devices. Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Signed-off-by: Pavel Machek <pavel@ucw.cz>
2019-11-03leds: bcm6358: Use devm_platform_ioremap_resource() in bcm6358_leds_probe()Markus Elfring1-6/+1
Simplify this function implementation by using a known wrapper function. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Pavel Machek <pavel@ucw.cz>
2019-11-03leds: bcm6328: Use devm_platform_ioremap_resource() in bcm6328_leds_probe()Markus Elfring1-6/+1
Simplify this function implementation by using a known wrapper function. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Pavel Machek <pavel@ucw.cz>
2019-11-03drivers: leds: tlc591xx: check error during device initDaniel Mack1-1/+4
The driver currently ignores errors from register writes at probe time. It will hence register an LED class device no matter whether the pyhsical device is present or not. To fix this, make the device probe fail in case regmap operations return an error. Signed-off-by: Daniel Mack <daniel@zonque.org> Signed-off-by: Pavel Machek <pavel@ucw.cz>
2019-11-03leds: add LED driver for EL15203000 boardOleh Kravchenko4-0/+510
This patch adds a LED class driver for the LEDs found on the Crane Merchandising System EL15203000 LEDs board (aka RED LEDs board). Signed-off-by: Oleh Kravchenko <oleg@kaa.org.ua> Reviewed-by: Dan Murphy <dmurphy@ti.com> Signed-off-by: Pavel Machek <pavel@ucw.cz>