ALSA: hda - VIA: Fix invalid A-A path volume adjust issue

Modify vt_auto_create_analog_input_ctls() function to fix invalid a-a path
volume adjust issue for VT1708S, VT1702 and VT1716S codecs.

Signed-off-by: Lydia Wang <lydiawang@viatech.com.cn>
Cc: <stable@kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
Lydia Wang 2011-03-22 16:24:10 +08:00 committed by Takashi Iwai
parent ab657e0cac
commit 169222813e
1 changed files with 8 additions and 1 deletions

View File

@ -2456,7 +2456,14 @@ static int vt_auto_create_analog_input_ctls(struct hda_codec *codec,
else
type_idx = 0;
label = hda_get_autocfg_input_label(codec, cfg, i);
err = via_new_analog_input(spec, label, type_idx, idx, cap_nid);
if (spec->codec_type == VT1708S ||
spec->codec_type == VT1702 ||
spec->codec_type == VT1716S)
err = via_new_analog_input(spec, label, type_idx,
idx+1, cap_nid);
else
err = via_new_analog_input(spec, label, type_idx,
idx, cap_nid);
if (err < 0)
return err;
snd_hda_add_imux_item(imux, label, idx, NULL);