summaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorwen yang <yellowriver2010@hotmail.com>2019-02-02 14:53:16 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-04-05 22:34:43 +0200
commit0da521452109f8ed6a75bee4d19973dcc71a6b85 (patch)
treef5cae307fe097ef7f7fe6d6926f19c5cc65d8875 /sound
parent8a838b44f70f349dfa1ee7f4fa9c1d65cc17f397 (diff)
downloadtalos-obmc-linux-0da521452109f8ed6a75bee4d19973dcc71a6b85.tar.gz
talos-obmc-linux-0da521452109f8ed6a75bee4d19973dcc71a6b85.zip
ASoC: fsl-asoc-card: fix object reference leaks in fsl_asoc_card_probe
[ Upstream commit 11907e9d3533648615db08140e3045b829d2c141 ] The of_find_device_by_node() takes a reference to the underlying device structure, we should release that reference. Signed-off-by: Wen Yang <yellowriver2010@hotmil.com> Cc: Timur Tabi <timur@kernel.org> Cc: Nicolin Chen <nicoleotsuka@gmail.com> Cc: Xiubo Li <Xiubo.Lee@gmail.com> Cc: Fabio Estevam <festevam@gmail.com> Cc: Liam Girdwood <lgirdwood@gmail.com> Cc: Mark Brown <broonie@kernel.org> Cc: Jaroslav Kysela <perex@perex.cz> Cc: Takashi Iwai <tiwai@suse.com> Cc: alsa-devel@alsa-project.org Cc: linuxppc-dev@lists.ozlabs.org Cc: linux-kernel@vger.kernel.org Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'sound')
-rw-r--r--sound/soc/fsl/fsl-asoc-card.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/sound/soc/fsl/fsl-asoc-card.c b/sound/soc/fsl/fsl-asoc-card.c
index 81f2fe2c6d23..60f87a0d99f4 100644
--- a/sound/soc/fsl/fsl-asoc-card.c
+++ b/sound/soc/fsl/fsl-asoc-card.c
@@ -689,6 +689,7 @@ static int fsl_asoc_card_probe(struct platform_device *pdev)
asrc_fail:
of_node_put(asrc_np);
of_node_put(codec_np);
+ put_device(&cpu_pdev->dev);
fail:
of_node_put(cpu_np);
OpenPOWER on IntegriCloud