From: Miaoqian Lin Date: Tue, 8 Mar 2022 07:19:42 +0000 (+0000) Subject: soc: qcom: smp2p: Fix missing of_node_put() in smp2p_parse_ipc X-Git-Tag: v6.1-rc5~1258^2~1^2~30 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=8fd3f18ea31a398ecce4a6d3804433658678b0a3;p=platform%2Fkernel%2Flinux-starfive.git soc: qcom: smp2p: Fix missing of_node_put() in smp2p_parse_ipc The device_node pointer is returned by of_parse_phandle() with refcount incremented. We should use of_node_put() on it when done. Fixes: 50e99641413e ("soc: qcom: smp2p: Qualcomm Shared Memory Point to Point") Signed-off-by: Miaoqian Lin Signed-off-by: Bjorn Andersson Link: https://lore.kernel.org/r/20220308071942.22942-1-linmq006@gmail.com --- diff --git a/drivers/soc/qcom/smp2p.c b/drivers/soc/qcom/smp2p.c index 4a15724..59dbf4b 100644 --- a/drivers/soc/qcom/smp2p.c +++ b/drivers/soc/qcom/smp2p.c @@ -493,6 +493,7 @@ static int smp2p_parse_ipc(struct qcom_smp2p *smp2p) } smp2p->ipc_regmap = syscon_node_to_regmap(syscon); + of_node_put(syscon); if (IS_ERR(smp2p->ipc_regmap)) return PTR_ERR(smp2p->ipc_regmap);