android_kernel_motorola_sm6225/drivers/leds
Christophe JAILLET 09f064fcad leds: ktd2692: Fix an error handling path
[ Upstream commit ee78b9360e14c276f5ceaa4a0d06f790f04ccdad ]

In 'ktd2692_parse_dt()', if an error occurs after a successful
'regulator_enable()' call, we should call 'regulator_enable()'.

This is the same in 'ktd2692_probe()', if an error occurs after a
successful 'ktd2692_parse_dt()' call.

Instead of adding 'regulator_enable()' in several places, implement a
resource managed solution and simplify the remove function accordingly.

Fixes: b7da8c5c72 ("leds: Add ktd2692 flash LED driver")
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-07-20 16:15:57 +02:00
..
trigger leds: trigger: netdev: fix handling on interface rename 2019-12-17 20:35:54 +01:00
Kconfig leds: Modify PC Engines apu/apu2 driver to support apu3 2018-06-28 21:34:43 +02:00
led-class-flash.c
led-class.c leds: core: Flush scheduled work for system suspend 2020-08-19 08:14:56 +02:00
led-core.c
led-triggers.c leds: trigger: fix potential deadlock with libata 2021-02-03 23:23:25 +01:00
leds-88pm860x.c leds: 88pm860x: fix use-after-free on unbind 2020-08-11 15:32:32 +02:00
leds-aat1290.c
leds-adp5520.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
leds-apu.c leds: Modify PC Engines apu/apu2 driver to support apu3 2018-06-28 21:34:43 +02:00
leds-as3645a.c leds: as3645a: Fix error return code in as3645a_parse_node() 2021-07-20 16:15:57 +02:00
leds-asic3.c
leds-bcm6328.c leds: bcm6328, bcm6358: use devres LED registering function 2020-11-05 11:08:46 +01:00
leds-bcm6358.c leds: bcm6328, bcm6358: use devres LED registering function 2020-11-05 11:08:46 +01:00
leds-bd2802.c
leds-blinkm.c
leds-clevo-mail.c
leds-cobalt-qube.c
leds-cobalt-raq.c
leds-cpcap.c
leds-cr0014114.c leds: Use struct_size() in allocation 2018-06-12 16:19:22 -07:00
leds-da903x.c leds: da903x: fix use-after-free on unbind 2020-08-11 15:32:32 +02:00
leds-da9052.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
leds-dac124s085.c
leds-fsg.c
leds-gpio-register.c
leds-gpio.c
leds-hp6xx.c
leds-ipaq-micro.c
leds-is31fl32xx.c
leds-is31fl319x.c
leds-ktd2692.c leds: ktd2692: Fix an error handling path 2021-07-20 16:15:57 +02:00
leds-lm355x.c leds: lm355x: avoid enum conversion warning 2020-08-19 08:14:54 +02:00
leds-lm3530.c
leds-lm3533.c leds: lm3533: fix use-after-free on unbind 2020-08-11 15:32:32 +02:00
leds-lm3601x.c leds: lm3601x: Introduce the lm3601x LED driver 2018-05-23 21:44:47 +02:00
leds-lm3642.c
leds-lm3692x.c leds: lm3692x: Handle failure to probe the regulator 2020-01-04 19:12:43 +01:00
leds-locomo.c
leds-lp55xx-common.c leds: lp55xx: fix null deref on firmware load failure 2019-04-05 22:33:07 +02:00
leds-lp55xx-common.h
leds-lp3944.c
leds-lp3952.c
leds-lp5521.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
leds-lp5523.c leds: lp5523: check return value of lp5xx_read and jump to cleanup code 2021-05-26 11:48:35 +02:00
leds-lp5562.c leds: leds-lp5562 allow firmware files up to the maximum length 2019-10-05 13:09:34 +02:00
leds-lp8501.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
leds-lp8788.c
leds-lp8860.c
leds-lt3593.c leds: lt3593: update email address and switch to SPDX license header 2018-07-03 22:12:41 +02:00
leds-max8997.c leds: max8997: use mode when calling max8997_led_set_mode 2018-07-03 22:12:41 +02:00
leds-max77693.c
leds-mc13783.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
leds-menf21bmc.c
leds-mlxcpld.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
leds-mlxreg.c leds: mlxreg: Fix possible buffer overflow 2020-10-01 13:14:25 +02:00
leds-mt6323.c
leds-net48xx.c
leds-netxbig.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
leds-nic78bx.c
leds-ns2.c leds: ns2: Change unsigned to unsigned int 2018-08-06 23:03:12 +02:00
leds-ot200.c
leds-pca955x.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
leds-pca963x.c leds: pca963x: Fix open-drain initialization 2020-02-24 08:34:35 +01:00
leds-pca9532.c leds: pca9532: fix a potential NULL pointer dereference 2019-05-04 09:20:22 +02:00
leds-pm8058.c
leds-powernv.c
leds-pwm.c leds: pwm: silently error out on EPROBE_DEFER 2019-01-13 09:51:08 +01:00
leds-rb532.c
leds-regulator.c
leds-s3c24xx.c
leds-sc27xx-bltc.c leds: sc27xx: Fix return value check in sc27xx_led_probe() 2018-05-22 21:57:59 +02:00
leds-ss4200.c
leds-sunfire.c
leds-syscon.c
leds-tca6507.c treewide: devm_kzalloc() -> devm_kcalloc() 2018-06-12 16:19:22 -07:00
leds-tlc591xx.c
leds-wm831x-status.c leds: wm831x-status: fix use-after-free on unbind 2020-08-11 15:32:32 +02:00
leds-wm8350.c
leds-wrap.c
leds.h
Makefile leds: lm3601x: Introduce the lm3601x LED driver 2018-05-23 21:44:47 +02:00
uleds.c