Skip to content

Commit

Permalink
ASoC: simple-card: Add missing of_node_put() in case of error
Browse files Browse the repository at this point in the history
In the error path, a of_node_put() for platform is missing.
Just add it.

Signed-off-by: Herve Codina <herve.codina@bootlin.com>
Acked-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Link: https://lore.kernel.org/r/20230523151223.109551-9-herve.codina@bootlin.com
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Herve Codina authored and Mark Brown committed May 26, 2023
1 parent 2d7c2f9 commit 8938f75
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions sound/soc/generic/simple-card.c
Original file line number Diff line number Diff line change
Expand Up @@ -416,6 +416,7 @@ static int __simple_for_each_link(struct asoc_simple_priv *priv,

if (ret < 0) {
of_node_put(codec);
of_node_put(plat);
of_node_put(np);
goto error;
}
Expand Down

0 comments on commit 8938f75

Please sign in to comment.