aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/sound/soc/intel/boards/skl_hda_dsp_common.c
diff options
context:
space:
mode:
authorLibin Yang <libin.yang@intel.com>2019-08-08 14:27:34 -0500
committerMark Brown <broonie@kernel.org>2019-08-08 20:57:01 +0100
commit0e4cc44f5066b22938f384cd57db99d66311de90 (patch)
treeae9b56e5423d1ddffa6f4d19904f6407621dcd09 /sound/soc/intel/boards/skl_hda_dsp_common.c
parentASoC: tscs454: remove unused variable 'PLL_48K_RATE' (diff)
downloadwireguard-linux-0e4cc44f5066b22938f384cd57db99d66311de90.tar.xz
wireguard-linux-0e4cc44f5066b22938f384cd57db99d66311de90.zip
ASoC: intel: skl_hda_dsp_common: create HDMI jack kctl
This patch call snd_jack_add_new_kctl() to create the HDMI jack kctls. Userspace needs these kctls to detect the hdmi monitor hotplug. In /usr/share/alsa/ucm, the config file needs to assign a jack kctl to "JackControl" to let PA get the jack hotplug status. Signed-off-by: Libin Yang <libin.yang@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Link: https://lore.kernel.org/r/20190808192734.18286-1-pierre-louis.bossart@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/intel/boards/skl_hda_dsp_common.c')
-rw-r--r--sound/soc/intel/boards/skl_hda_dsp_common.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/sound/soc/intel/boards/skl_hda_dsp_common.c b/sound/soc/intel/boards/skl_hda_dsp_common.c
index 55fd82e05e2c..58409b6e476e 100644
--- a/sound/soc/intel/boards/skl_hda_dsp_common.c
+++ b/sound/soc/intel/boards/skl_hda_dsp_common.c
@@ -147,6 +147,11 @@ int skl_hda_hdmi_jack_init(struct snd_soc_card *card)
if (err)
return err;
+ err = snd_jack_add_new_kctl(pcm->hdmi_jack.jack,
+ jack_name, SND_JACK_AVOUT);
+ if (err)
+ dev_warn(component->dev, "failed creating Jack kctl\n");
+
err = hdac_hdmi_jack_init(pcm->codec_dai, pcm->device,
&pcm->hdmi_jack);
if (err < 0)