ASoC: topology: Fix bugs of freeing soc topology
In snd_soc_tplg_component_remove(), it should compare index and not dobj->index with SND_SOC_TPLG_INDEX_ALL for removing all topology objects. Signed-off-by: Yan Wang <yan.wang@linux.intel.com> Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
dc29f581fa
commit
feb12f0cd8
|
@ -2580,7 +2580,7 @@ int snd_soc_tplg_component_remove(struct snd_soc_component *comp, u32 index)
|
|||
|
||||
/* match index */
|
||||
if (dobj->index != index &&
|
||||
dobj->index != SND_SOC_TPLG_INDEX_ALL)
|
||||
index != SND_SOC_TPLG_INDEX_ALL)
|
||||
continue;
|
||||
|
||||
switch (dobj->type) {
|
||||
|
|
Loading…
Reference in New Issue