Skip to content

Commit f670b27

Browse files
Ye Guojinbroonie
authored andcommitted
ASoC: imx-hdmi: add put_device() after of_find_device_by_node()
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> Link: https://lore.kernel.org/r/20211110002910.134915-1-ye.guojin@zte.com.cn Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 2b9c8d2 commit f670b27

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

sound/soc/fsl/imx-hdmi.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,8 @@ static int imx_hdmi_probe(struct platform_device *pdev)
145145
data->dai.capture_only = false;
146146
data->dai.init = imx_hdmi_init;
147147

148+
put_device(&cpu_pdev->dev);
149+
148150
if (of_node_name_eq(cpu_np, "sai")) {
149151
data->cpu_priv.sysclk_id[1] = FSL_SAI_CLK_MAST1;
150152
data->cpu_priv.sysclk_id[0] = FSL_SAI_CLK_MAST1;

0 commit comments

Comments
 (0)