diff options
author | Amadeusz Sławiński <amadeuszx.slawinski@intel.com> | 2019-01-25 21:06:43 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2019-01-29 19:03:13 +0100 |
commit | a46e8393d128d4e5f722b47f708a0d5de91e0176 (patch) | |
tree | 12e33294cfcfd3f16262e8b47edbab50fa6e53aa /sound/soc/soc-topology.c | |
parent | ASoC: topology: Reduce number of dereferences when accessing dobj (diff) | |
download | linux-a46e8393d128d4e5f722b47f708a0d5de91e0176.tar.xz linux-a46e8393d128d4e5f722b47f708a0d5de91e0176.zip |
ASoC: topology: Remove widgets from dobj list
Currently when we unload and reload machine driver few times we end with
corrupted list and try to cleanup no longer existing objects. Fix this
by removing dobj from the list.
Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/soc-topology.c')
-rw-r--r-- | sound/soc/soc-topology.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sound/soc/soc-topology.c b/sound/soc/soc-topology.c index b02c41614f96..abc2d804d5bf 100644 --- a/sound/soc/soc-topology.c +++ b/sound/soc/soc-topology.c @@ -493,6 +493,8 @@ static void remove_widget(struct snd_soc_component *comp, free_news: kfree(w->kcontrol_news); + list_del(&dobj->list); + /* widget w is freed by soc-dapm.c */ } |