diff options
author | Takashi Iwai <tiwai@suse.de> | 2013-03-07 18:30:27 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2013-03-07 18:30:27 +0100 |
commit | 3f550e323242bea82d07dfd06e6ce3f723eef7bd (patch) | |
tree | 9a142d2a7c6b25ad292a1ddf6e764d9ff73fdbf2 /sound/pci | |
parent | 5ebd3bbdcc17c9523dbbbf9c756da1676ca7e973 (diff) | |
download | op-kernel-dev-3f550e323242bea82d07dfd06e6ce3f723eef7bd.zip op-kernel-dev-3f550e323242bea82d07dfd06e6ce3f723eef7bd.tar.gz |
ALSA: hda - Allow to change I/O direction in hp/mic jack mode ctl
The previous commits added the capability to change the pin control of
hp/mic shared jack, but it actually didn't work as expected when the
value is changed from the output to the input, since I forgot to reset
the pin I/O bit in that case. This patch fixes the problem.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci')
-rw-r--r-- | sound/pci/hda/hda_generic.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sound/pci/hda/hda_generic.c b/sound/pci/hda/hda_generic.c index dc849e4..cb40a0b 100644 --- a/sound/pci/hda/hda_generic.c +++ b/sound/pci/hda/hda_generic.c @@ -2650,8 +2650,8 @@ static int hp_mic_jack_mode_put(struct snd_kcontrol *kcontrol, if (in_jacks > 1) { unsigned int vref_caps = get_vref_caps(codec, nid); val = snd_hda_codec_get_pin_target(codec, nid); - val &= ~AC_PINCTL_VREFEN; - val |= get_vref_idx(vref_caps, idx); + val &= ~(AC_PINCTL_VREFEN | PIN_HP); + val |= get_vref_idx(vref_caps, idx) | PIN_IN; } else val = snd_hda_get_default_vref(codec, nid); } |