ASoC: soc-topology: use devm_snd_soc_register_dai()
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Fri, 12 Jun 2020 20:59:38 +0000 (15:59 -0500)
committerMark Brown <broonie@kernel.org>
Mon, 15 Jun 2020 13:15:12 +0000 (14:15 +0100)
commit6ae4902f2f3400503f9b78e87e8371e4ffde1e0c
treef0a413e638179c4f8ec673e899b58eeb28fcc032
parent0fae253af563cf5d1f5dc651d520c3eafd74f183
ASoC: soc-topology: use devm_snd_soc_register_dai()

Use devm_ to avoid use-after-free KASAN reports and simplify error
handling.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Reviewed-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
BugLink: https://github.com/thesofproject/linux/issues/2186
Link: https://lore.kernel.org/r/20200612205938.26415-3-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/soc-topology.c