Patch "ASoC: rsnd: Fix an error handling path in 'rsnd_node_count()'" has been added to the 5.14-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    ASoC: rsnd: Fix an error handling path in 'rsnd_node_count()'

to the 5.14-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     asoc-rsnd-fix-an-error-handling-path-in-rsnd_node_co.patch
and it can be found in the queue-5.14 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit 96036e367d4f16b25d5838db6ef06836c5f4ba89
Author: Christophe JAILLET <christophe.jaillet@xxxxxxxxxx>
Date:   Mon Oct 18 21:44:16 2021 +0200

    ASoC: rsnd: Fix an error handling path in 'rsnd_node_count()'
    
    [ Upstream commit 173632358fde7a567f28e07c4549b959ee857986 ]
    
    If we return before the end of the 'for_each_child_of_node()' iterator, the
    reference taken on 'np' must be released.
    
    Add the missing 'of_node_put()' call.
    
    Fixes: c413983eb66a ("ASoC: rsnd: adjust disabled module")
    Signed-off-by: Christophe JAILLET <christophe.jaillet@xxxxxxxxxx>
    Reviewed-by: Kuninori Morimoto <kuninori.morimoto.gx@xxxxxxxxxxx>
    Link: https://lore.kernel.org/r/4c0e893cbfa21dc76c1ede0b6f4f8cff42209299.1634586167.git.christophe.jaillet@xxxxxxxxxx
    Signed-off-by: Mark Brown <broonie@xxxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/sound/soc/sh/rcar/core.c b/sound/soc/sh/rcar/core.c
index 5e382b5c9d457..ece9b58ab52d3 100644
--- a/sound/soc/sh/rcar/core.c
+++ b/sound/soc/sh/rcar/core.c
@@ -1225,6 +1225,7 @@ int rsnd_node_count(struct rsnd_priv *priv, struct device_node *node, char *name
 		if (i < 0) {
 			dev_err(dev, "strange node numbering (%s)",
 				of_node_full_name(node));
+			of_node_put(np);
 			return 0;
 		}
 		i++;



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux