From: Liang He Date: Wed, 22 Mar 2023 03:56:27 +0000 (+0800) Subject: iio: dac: ad5755: Add missing fwnode_handle_put() X-Git-Tag: v6.2.13~54 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0d6eb21f361deb835c4a943d7a69bd56e2230534;p=thirdparty%2Fkernel%2Fstable.git iio: dac: ad5755: Add missing fwnode_handle_put() commit ffef73791574b8da872cfbf881d8e3e9955fc130 upstream. In ad5755_parse_fw(), we should add fwnode_handle_put() when break out of the iteration device_for_each_child_node() as it will automatically increase and decrease the refcounter. Fixes: 3ac27afefd5d ("iio:dac:ad5755: Switch to generic firmware properties and drop pdata") Signed-off-by: Liang He Link: https://lore.kernel.org/r/20230322035627.1856421-1-windhl@126.com Cc: Signed-off-by: Jonathan Cameron Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/iio/dac/ad5755.c b/drivers/iio/dac/ad5755.c index beadfa938d2da..404865e354602 100644 --- a/drivers/iio/dac/ad5755.c +++ b/drivers/iio/dac/ad5755.c @@ -802,6 +802,7 @@ static struct ad5755_platform_data *ad5755_parse_fw(struct device *dev) return pdata; error_out: + fwnode_handle_put(pp); devm_kfree(dev, pdata); return NULL; }