]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: Intel: Skylake: Remove static table index when parsing topology
authorAmadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Fri, 26 Jul 2019 09:09:29 +0000 (11:09 +0200)
committerMark Brown <broonie@kernel.org>
Fri, 26 Jul 2019 16:09:35 +0000 (17:09 +0100)
commit38a5ab17a9f5aa1daf42658db51af0fad9b275c9
treecba6561a1779f259cd4cbdfadbae1e3dec546f3c
parent217d01e2009c041033c18a03b5093b3ed0fc78d5
ASoC: Intel: Skylake: Remove static table index when parsing topology

Currently when we remove and reload driver we use previous ref_count
value to start iterating over skl->modules which leads to out of table
access. To fix this just inline the function and calculate indexes
everytime we parse UUID token.

Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20190726090929.27946-2-amadeuszx.slawinski@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/intel/skylake/skl-topology.c