aboutsummaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorDavid Henningsson <david.henningsson@canonical.com>2013-02-22 04:16:28 -0500
committerTakashi Iwai <tiwai@suse.de>2013-02-22 04:23:32 -0500
commit30efd8debd1ef30be342d374f01e993509f5b76b (patch)
tree06379e32cfb704cb420c5d35d61deb3c8a3406af /sound
parentb531f81b0d70ffbe8d70500512483227cc532608 (diff)
ALSA: hda - hdmi: Make jacks phantom, if they're not detectable
Just as for analog codecs, a jack that isn't suitable for detection (in this case, NO_PRESENCE was set) should be a phantom Jack instead of a normal one. Thanks to Raymond Yau for spotting. Cc: stable@vger.kernel.org BugLink: https://bugs.launchpad.net/bugs/961286 BugLink: https://bugzilla.redhat.com/show_bug.cgi?id=903869 Signed-off-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound')
-rw-r--r--sound/pci/hda/patch_hdmi.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c
index 21425fb51fe0..78e1827d0a95 100644
--- a/sound/pci/hda/patch_hdmi.c
+++ b/sound/pci/hda/patch_hdmi.c
@@ -1640,6 +1640,9 @@ static int generic_hdmi_build_jack(struct hda_codec *codec, int pin_idx)
1640 1640
1641 if (pcmdev > 0) 1641 if (pcmdev > 0)
1642 sprintf(hdmi_str + strlen(hdmi_str), ",pcm=%d", pcmdev); 1642 sprintf(hdmi_str + strlen(hdmi_str), ",pcm=%d", pcmdev);
1643 if (!is_jack_detectable(codec, per_pin->pin_nid))
1644 strncat(hdmi_str, " Phantom",
1645 sizeof(hdmi_str) - strlen(hdmi_str) - 1);
1643 1646
1644 return snd_hda_jack_add_kctl(codec, per_pin->pin_nid, hdmi_str, 0); 1647 return snd_hda_jack_add_kctl(codec, per_pin->pin_nid, hdmi_str, 0);
1645} 1648}