From: Liang He Date: Sat, 2 Jul 2022 02:01:09 +0000 (+0800) Subject: ASoC: qcom: Fix missing of_node_put() in asoc_qcom_lpass_cpu_platform_probe() X-Git-Tag: baikal/mips/sdk5.9~190 X-Git-Url: https://git.baikalelectronics.ru/sdk/?a=commitdiff_plain;h=af74cc087dbe06c8b0af0c27ec99b1c3c0cd151e;p=kernel.git ASoC: qcom: Fix missing of_node_put() in asoc_qcom_lpass_cpu_platform_probe() [ Upstream commit d6d306560fa3e3b8e74fd63205dd21730dd6f951 ] We should call of_node_put() for the reference 'dsp_of_node' returned by of_parse_phandle() which will increase the refcount. Fixes: 41d9a7422b1e ("ASoC: qcom: move ipq806x specific bits out of lpass driver.") Co-authored-by: Miaoqian Lin Signed-off-by: Liang He Link: https://lore.kernel.org/r/20220702020109.263980-1-windhl@126.com Signed-off-by: Mark Brown Signed-off-by: Sasha Levin --- diff --git a/sound/soc/qcom/lpass-cpu.c b/sound/soc/qcom/lpass-cpu.c index 3bd9eb3cc688b..5e89d280e3550 100644 --- a/sound/soc/qcom/lpass-cpu.c +++ b/sound/soc/qcom/lpass-cpu.c @@ -880,6 +880,7 @@ int asoc_qcom_lpass_cpu_platform_probe(struct platform_device *pdev) dsp_of_node = of_parse_phandle(pdev->dev.of_node, "qcom,adsp", 0); if (dsp_of_node) { dev_err(dev, "DSP exists and holds audio resources\n"); + of_node_put(dsp_of_node); return -EBUSY; }