From: Pierre-Louis Bossart Date: Thu, 14 Apr 2022 18:48:09 +0000 (-0500) Subject: ASoC: SOF: sof-audio: preserve topology filename override in nocodec mode X-Git-Tag: v6.6-pxa1908~3812^2~2^2~117^2~8 X-Git-Url: https://git.dujemihanovic.xyz/?a=commitdiff_plain;h=53fe24c2c76383712bedee6a9e4ebe2ec595345b;p=linux.git ASoC: SOF: sof-audio: preserve topology filename override in nocodec mode If the topology filename is modified at a higher level, be it with a DMI quirk or a kernel module parameter, we don't want to use the default 'nocodec' topology name extracted from descriptors. Signed-off-by: Pierre-Louis Bossart Reviewed-by: Ranjani Sridharan Reviewed-by: Daniel Baluta Reviewed-by: Paul Olaru Reviewed-by: Péter Ujfalusi Link: https://lore.kernel.org/r/20220414184817.362215-8-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown --- diff --git a/sound/soc/sof/sof-audio.c b/sound/soc/sof/sof-audio.c index c0a442272ad6..e2ec60887568 100644 --- a/sound/soc/sof/sof-audio.c +++ b/sound/soc/sof/sof-audio.c @@ -652,7 +652,8 @@ int sof_machine_check(struct snd_sof_dev *sdev) return -ENOMEM; mach->drv_name = "sof-nocodec"; - sof_pdata->tplg_filename = desc->nocodec_tplg_filename; + if (!sof_pdata->tplg_filename) + sof_pdata->tplg_filename = desc->nocodec_tplg_filename; sof_pdata->machine = mach; snd_sof_set_mach_params(mach, sdev);