diff options
author | Silviu-Mihai Popescu <silviupopescu1990@gmail.com> | 2013-03-16 15:45:34 +0400 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2013-03-20 14:05:56 +0400 |
commit | f7ba716f1e704a00d682a8697108f9c86497c551 (patch) | |
tree | 29ad6e35139a06673b4653926f649302b284a2d8 /sound/soc/soc-core.c | |
parent | e8b18addee32d1f389573b4c116e67ae230216ad (diff) | |
download | linux-f7ba716f1e704a00d682a8697108f9c86497c551.tar.xz |
ASoC: core: fix invalid free of devm_ allocated data
The objects allocated by devm_* APIs are managed by devres and are freed when
the device is detached. Hence there is no need to use kfree() explicitly.
Signed-off-by: Silviu-Mihai Popescu <silviupopescu1990@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/soc-core.c')
-rw-r--r-- | sound/soc/soc-core.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/sound/soc/soc-core.c b/sound/soc/soc-core.c index 93341deaa4b9..507d251916af 100644 --- a/sound/soc/soc-core.c +++ b/sound/soc/soc-core.c @@ -4199,7 +4199,6 @@ int snd_soc_of_parse_audio_routing(struct snd_soc_card *card, dev_err(card->dev, "ASoC: Property '%s' index %d could not be read: %d\n", propname, 2 * i, ret); - kfree(routes); return -EINVAL; } ret = of_property_read_string_index(np, propname, @@ -4208,7 +4207,6 @@ int snd_soc_of_parse_audio_routing(struct snd_soc_card *card, dev_err(card->dev, "ASoC: Property '%s' index %d could not be read: %d\n", propname, (2 * i) + 1, ret); - kfree(routes); return -EINVAL; } } |