]> git.baikalelectronics.ru Git - kernel.git/commit
of: device: Fix missing of_node_put() in of_dma_set_restricted_buffer
authorLiang He <windhl@126.com>
Sat, 2 Jul 2022 01:44:49 +0000 (09:44 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Aug 2022 12:23:51 +0000 (14:23 +0200)
commitf42f7108c816d5e30e64beed1249dfec78c1ff72
treeca1fbca61afdbb333331f7e79ce5042291870d2a
parent5cc18e54d839047185ebcd16f1a32bbb733d3d77
of: device: Fix missing of_node_put() in of_dma_set_restricted_buffer

[ Upstream commit 608cf2b430a77df76a42bd89dceda57a773e6394 ]

We should use of_node_put() for the reference 'node' returned by
of_parse_phandle() which will increase the refcount.

Fixes: c06c267f97ed ("of: Add plumbing for restricted DMA pool")
Co-authored-by: Miaoqian Lin <linmq006@gmail.com>
Signed-off-by: Liang He <windhl@126.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220702014449.263772-1-windhl@126.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/of/device.c