aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Ujfalusi <[email protected]>2023-11-24 14:40:15 +0200
committerMark Brown <[email protected]>2023-11-24 12:55:04 +0000
commit3d1dc8b1030df8ca0fdfd4905c88ee10db943bf8 (patch)
tree8ab6b26246abc4204deffd61dfe02030cb918c2b
parent347ecf29a68cc8958fbcbd26ef410d07fe9d82f4 (diff)
ASoC: Intel: skl_hda_dsp_generic: Drop HDMI routes when HDMI is not available
When the HDMI is not present due to disabled display support we will use dummy codec and the HDMI routes will refer to non existent DAPM widgets. Trim the route list from the HDMI routes to be able to probe the card even if the HDMI dais are not registered. Signed-off-by: Peter Ujfalusi <[email protected]> Reviewed-by: Bard Liao <[email protected]> Reviewed-by: Kai Vehmanen <[email protected]> Reviewed-by: Pierre-Louis Bossart <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Mark Brown <[email protected]>
-rw-r--r--sound/soc/intel/boards/skl_hda_dsp_generic.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sound/soc/intel/boards/skl_hda_dsp_generic.c b/sound/soc/intel/boards/skl_hda_dsp_generic.c
index 6c6ef63cd5d9..6e172719c979 100644
--- a/sound/soc/intel/boards/skl_hda_dsp_generic.c
+++ b/sound/soc/intel/boards/skl_hda_dsp_generic.c
@@ -154,6 +154,8 @@ static int skl_hda_fill_card_info(struct snd_soc_acpi_mach_params *mach_params)
card->dapm_widgets = skl_hda_widgets;
card->num_dapm_widgets = ARRAY_SIZE(skl_hda_widgets);
if (!ctx->idisp_codec) {
+ card->dapm_routes = &skl_hda_map[IDISP_ROUTE_COUNT];
+ num_route -= IDISP_ROUTE_COUNT;
for (i = 0; i < IDISP_DAI_COUNT; i++) {
skl_hda_be_dai_links[i].codecs = &snd_soc_dummy_dlc;
skl_hda_be_dai_links[i].num_codecs = 1;