dmaengine: xilinx_dma: call of_node_put() when breaking out of for_each_child_of_node()
authorLiu Shixin <liushixin2@huawei.com>
Tue, 22 Nov 2022 02:16:12 +0000 (10:16 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 1 Feb 2023 07:27:13 +0000 (08:27 +0100)
commit4095065b59bc3f3411059b1b0e890f626dfa091a
treeae5a89ee6f38d41c94e77a3e91a0fe2248a92c67
parent5bd3c1c1bce1c919ef2c68085cb84ed965581be2
dmaengine: xilinx_dma: call of_node_put() when breaking out of for_each_child_of_node()

[ Upstream commit 596b53ccc36a546ab28e8897315c5b4d1d5a0200 ]

Since for_each_child_of_node() will increase the refcount of node, we need
to call of_node_put() manually when breaking out of the iteration.

Fixes: 9cd4360de609 ("dma: Add Xilinx AXI Video Direct Memory Access Engine driver support")
Signed-off-by: Liu Shixin <liushixin2@huawei.com>
Acked-by: Peter Korsgaard <peter@korsgaard.com>
Link: https://lore.kernel.org/r/20221122021612.1908866-1-liushixin2@huawei.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/dma/xilinx/xilinx_dma.c