ASoC: amd: acp5x-mach:add checks to avoid static analysis warnings
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Mon, 31 Jul 2023 21:37:48 +0000 (16:37 -0500)
committerMark Brown <broonie@kernel.org>
Mon, 31 Jul 2023 22:22:18 +0000 (23:22 +0100)
commit871861f6ad6d43b49caade3f42b9d40ca1413e79
treeb179d8168e7e562c8748a9d72fcd8cfe09366ac1
parent71d76768fbe72aa70dd61d5714a5579dc4ca61cb
ASoC: amd: acp5x-mach:add checks to avoid static analysis warnings

snd_soc_card_get_codec_dai() can return NULL, but that value is not
checked for, leading to static analysis warnings.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Rander Wang <rander.wang@intel.com>
Reviewed-by: Daniel Baluta <daniel.baluta@nxp.com>
Reviewed-by: Yaochun Hung <yc.hung@mediatek.com>
Link: https://lore.kernel.org/r/20230731213748.440285-9-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/amd/vangogh/acp5x-mach.c