diff options
author | Lydia Wang <lydiawang@viatech.com.cn> | 2011-07-04 04:54:15 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2011-07-04 08:33:23 -0400 |
commit | c4394f5b807289c180a486df70c1a9b1f192f1cb (patch) | |
tree | e105a741d5187ce062743aa68a75b6dd68263777 /sound/pci | |
parent | e5e14681404ec27a422d635284bf564dabde3f81 (diff) |
ALSA: hda - Fix issue that front can't output sound for VT1718S
For VT1718S, Mixer 9 doesn't expose the connection to DAC 0. So when
building up a 'PCM Playback' amplifier control, it will fail since
getting DAC 0 index of Mixer 9 returned -1. So I added a dac_mixer_idx
to indicated the actual index of DAC 0 to Mixer 9. Following is the
patch and next mail is another.
Signed-off-by: Lydia Wang <lydiawang@viatech.com.cn>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci')
-rw-r--r-- | sound/pci/hda/patch_via.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sound/pci/hda/patch_via.c b/sound/pci/hda/patch_via.c index bbbc4f4cbf1a..89dd29db97e3 100644 --- a/sound/pci/hda/patch_via.c +++ b/sound/pci/hda/patch_via.c | |||
@@ -130,6 +130,7 @@ struct via_spec { | |||
130 | hda_nid_t hp_dac_nid; | 130 | hda_nid_t hp_dac_nid; |
131 | bool hp_indep_shared; /* indep HP-DAC is shared with side ch */ | 131 | bool hp_indep_shared; /* indep HP-DAC is shared with side ch */ |
132 | int num_active_streams; | 132 | int num_active_streams; |
133 | int dac_mixer_idx; | ||
133 | 134 | ||
134 | struct nid_path out_path[4]; | 135 | struct nid_path out_path[4]; |
135 | struct nid_path hp_path; | 136 | struct nid_path hp_path; |
@@ -1810,6 +1811,8 @@ static int via_auto_create_multi_out_ctls(struct hda_codec *codec) | |||
1810 | 1811 | ||
1811 | idx = get_connection_index(codec, spec->aa_mix_nid, | 1812 | idx = get_connection_index(codec, spec->aa_mix_nid, |
1812 | spec->multiout.dac_nids[0]); | 1813 | spec->multiout.dac_nids[0]); |
1814 | if (idx < 0 && spec->dac_mixer_idx) | ||
1815 | idx = spec->dac_mixer_idx; | ||
1813 | if (idx >= 0) { | 1816 | if (idx >= 0) { |
1814 | /* add control to mixer */ | 1817 | /* add control to mixer */ |
1815 | err = via_add_control(spec, VIA_CTL_WIDGET_VOL, | 1818 | err = via_add_control(spec, VIA_CTL_WIDGET_VOL, |
@@ -2959,6 +2962,7 @@ static int patch_vt1718S(struct hda_codec *codec) | |||
2959 | spec->aa_mix_nid = 0x21; | 2962 | spec->aa_mix_nid = 0x21; |
2960 | override_mic_boost(codec, 0x2b, 0, 3, 40); | 2963 | override_mic_boost(codec, 0x2b, 0, 3, 40); |
2961 | override_mic_boost(codec, 0x29, 0, 3, 40); | 2964 | override_mic_boost(codec, 0x29, 0, 3, 40); |
2965 | spec->dac_mixer_idx = 5; | ||
2962 | 2966 | ||
2963 | /* automatic parse from the BIOS config */ | 2967 | /* automatic parse from the BIOS config */ |
2964 | err = via_parse_auto_config(codec); | 2968 | err = via_parse_auto_config(codec); |