From: cgel.zte@gmail.com
To: nicoleotsuka@gmail.com
Cc: alsa-devel@alsa-project.org, linuxppc-dev@lists.ozlabs.org,
linux-kernel@vger.kernel.org, Xiubo.Lee@gmail.com,
festevam@gmail.com, s.hauer@pengutronix.de, tiwai@suse.com,
lgirdwood@gmail.com, broonie@kernel.org, linux-imx@nxp.com,
kernel@pengutronix.de, Ye Guojin <ye.guojin@zte.com.cn>,
shawnguo@kernel.org, shengjiu.wang@gmail.com,
Zeal Robot <zealci@zte.com.cn>,
linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ASoC: imx-hdmi: add put_device() after of_find_device_by_node()
Date: Wed, 10 Nov 2021 00:29:10 +0000 [thread overview]
Message-ID: <20211110002910.134915-1-ye.guojin@zte.com.cn> (raw)
From: Ye Guojin <ye.guojin@zte.com.cn>
This was found by coccicheck:
./sound/soc/fsl/imx-hdmi.c,209,1-7,ERROR missing put_device; call
of_find_device_by_node on line 119, but without a corresponding object
release within this function.
Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Ye Guojin <ye.guojin@zte.com.cn>
---
sound/soc/fsl/imx-hdmi.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/sound/soc/fsl/imx-hdmi.c b/sound/soc/fsl/imx-hdmi.c
index f10359a28800..929f69b758af 100644
--- a/sound/soc/fsl/imx-hdmi.c
+++ b/sound/soc/fsl/imx-hdmi.c
@@ -145,6 +145,8 @@ static int imx_hdmi_probe(struct platform_device *pdev)
data->dai.capture_only = false;
data->dai.init = imx_hdmi_init;
+ put_device(&cpu_pdev->dev);
+
if (of_node_name_eq(cpu_np, "sai")) {
data->cpu_priv.sysclk_id[1] = FSL_SAI_CLK_MAST1;
data->cpu_priv.sysclk_id[0] = FSL_SAI_CLK_MAST1;
--
2.25.1
next reply other threads:[~2021-11-10 0:30 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-10 0:29 cgel.zte [this message]
2021-11-27 1:29 ` [PATCH] ASoC: imx-hdmi: add put_device() after of_find_device_by_node() Mark Brown
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20211110002910.134915-1-ye.guojin@zte.com.cn \
--to=cgel.zte@gmail.com \
--cc=Xiubo.Lee@gmail.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=festevam@gmail.com \
--cc=kernel@pengutronix.de \
--cc=lgirdwood@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-imx@nxp.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=nicoleotsuka@gmail.com \
--cc=s.hauer@pengutronix.de \
--cc=shawnguo@kernel.org \
--cc=shengjiu.wang@gmail.com \
--cc=tiwai@suse.com \
--cc=ye.guojin@zte.com.cn \
--cc=zealci@zte.com.cn \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).