Commit 1aafcd4d authored by Dimitris Papastamos's avatar Dimitris Papastamos Committed by Mark Brown

ASoC: soc-core: Fix codec->name memory leak

Ensure that the codec->name is freed when unregistering the codec.
Signed-off-by: default avatarDimitris Papastamos <dp@opensource.wolfsonmicro.com>
Acked-by: default avatarLiam Girdwood <lrg@slimlogic.co.uk>
Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
parent c429ffbe
......@@ -3299,6 +3299,7 @@ void snd_soc_unregister_codec(struct device *dev)
if (codec->reg_cache)
kfree(codec->reg_cache);
kfree(codec->name);
kfree(codec);
}
EXPORT_SYMBOL_GPL(snd_soc_unregister_codec);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment