linux/drivers/slimbus
Nishka Dasgupta 04eb94d526 slimbus: qcom-ngd-ctrl: Add of_node_put() before return
Each iteration of for_each_available_child_of_node puts the previous
node, but in the case of a return from the middle of the loop, there is
no put, thus causing a memory leak. Hence add an of_node_put before the
return in two places.
Issue found with Coccinelle.

Signed-off-by: Nishka Dasgupta <nishkadg.linux@gmail.com>
Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Link: https://lore.kernel.org/r/20190818093902.29993-2-srinivas.kandagatla@linaro.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-08-18 12:56:10 +02:00
..
core.c slimbus: core: generate uevent for non-dt only 2019-06-20 10:45:22 +02:00
Kconfig slimbus: ngd: QCOM_QMI_HELPERS has to be selected 2018-11-27 08:44:06 +01:00
Makefile slimbus: stream: add stream support 2018-07-07 17:25:23 +02:00
messaging.c slimbus: messaging: add slim_alloc/free_txn_tid() 2018-07-07 17:24:32 +02:00
qcom-ctrl.c slimbus: remove redundant dev_err message 2019-06-20 10:45:22 +02:00
qcom-ngd-ctrl.c slimbus: qcom-ngd-ctrl: Add of_node_put() before return 2019-08-18 12:56:10 +02:00
sched.c slimbus: Add support for 'clock-pause' feature 2017-12-19 11:01:03 +01:00
slimbus.h slimbus: ngd: remove unnecessary check 2018-11-07 14:59:28 +01:00
stream.c slimbus: fix kerneldoc comments 2019-06-10 18:44:21 +02:00