[PATCH v2 3/3] leds: flash: leds-qcom-flash: put child node if registration failed

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Put the child node if register flash LED device failed.

Signed-off-by: Fenglin Wu <quic_fenglinw@xxxxxxxxxxx>
---
 drivers/leds/flash/leds-qcom-flash.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/leds/flash/leds-qcom-flash.c b/drivers/leds/flash/leds-qcom-flash.c
index 29cf09479422..a73d3ea5c97a 100644
--- a/drivers/leds/flash/leds-qcom-flash.c
+++ b/drivers/leds/flash/leds-qcom-flash.c
@@ -749,6 +749,7 @@ static int qcom_flash_led_probe(struct platform_device *pdev)
 	return 0;
 
 release:
+	fwnode_handle_put(child);
 	while (flash_data->v4l2_flash[flash_data->leds_count] && flash_data->leds_count)
 		v4l2_flash_release(flash_data->v4l2_flash[flash_data->leds_count--]);
 	return rc;

-- 
2.25.1




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [Linux for Sparc]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux