ASoC: Intel: sof_pcm512x: make HDMI optional for all platforms
authorKai Vehmanen <kai.vehmanen@linux.intel.com>
Thu, 12 Mar 2020 19:48:52 +0000 (14:48 -0500)
committerMark Brown <broonie@kernel.org>
Fri, 13 Mar 2020 15:44:51 +0000 (15:44 +0000)
commit15a5a89597e57e67d4dde1d57fa85105c5930bb3
treec3aec744989f0ff6e723cd5953f75b0352970a57
parent4399afd21a0169a125a16c2dbba68f7d9a2cffdb
ASoC: Intel: sof_pcm512x: make HDMI optional for all platforms

Make HDMI optional for APL and later platforms. If no HDMI codec
is found on the HDA bus, the graphics side driver is missing or
correct codec driver is not part of kernel build, codec_mask
reflects this and HDMI is disabled. The DSP topology will still
have the links for HDMI, so connect these to dummy codec to avoid
failures in topology loading.

This change also fixes a kernel oops that was triggered if
sof_pcm512x was used with SOF configured to use hdac-hdmi (can be
done via "use_common_hdmi=0" or by selecting
CONFIG_SND_SOC_SOF_HDA_COMMON_HDMI_CODEC=n). This is not a supported
configuration.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20200312194859.4051-4-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/intel/boards/sof_pcm512x.c