aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/hda/patch_analog.c
diff options
context:
space:
mode:
Diffstat (limited to 'sound/pci/hda/patch_analog.c')
-rw-r--r--sound/pci/hda/patch_analog.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/sound/pci/hda/patch_analog.c b/sound/pci/hda/patch_analog.c
index 32401bd8c229..2bfe37e8543c 100644
--- a/sound/pci/hda/patch_analog.c
+++ b/sound/pci/hda/patch_analog.c
@@ -44,6 +44,7 @@ struct ad198x_spec {
44 * dig_out_nid and hp_nid are optional 44 * dig_out_nid and hp_nid are optional
45 */ 45 */
46 unsigned int cur_eapd; 46 unsigned int cur_eapd;
47 unsigned int need_dac_fix;
47 48
48 /* capture */ 49 /* capture */
49 unsigned int num_adc_nids; 50 unsigned int num_adc_nids;
@@ -836,10 +837,14 @@ static int patch_ad1986a(struct hda_codec *codec)
836 case AD1986A_3STACK: 837 case AD1986A_3STACK:
837 spec->num_mixers = 2; 838 spec->num_mixers = 2;
838 spec->mixers[1] = ad1986a_3st_mixers; 839 spec->mixers[1] = ad1986a_3st_mixers;
839 spec->num_init_verbs = 2; 840 spec->num_init_verbs = 3;
840 spec->init_verbs[1] = ad1986a_3st_init_verbs; 841 spec->init_verbs[1] = ad1986a_3st_init_verbs;
842 spec->init_verbs[2] = ad1986a_ch2_init;
841 spec->channel_mode = ad1986a_modes; 843 spec->channel_mode = ad1986a_modes;
842 spec->num_channel_mode = ARRAY_SIZE(ad1986a_modes); 844 spec->num_channel_mode = ARRAY_SIZE(ad1986a_modes);
845 spec->need_dac_fix = 1;
846 spec->multiout.max_channels = 2;
847 spec->multiout.num_dacs = 1;
843 break; 848 break;
844 case AD1986A_LAPTOP: 849 case AD1986A_LAPTOP:
845 spec->mixers[0] = ad1986a_laptop_mixers; 850 spec->mixers[0] = ad1986a_laptop_mixers;
@@ -1555,6 +1560,8 @@ static int ad198x_ch_mode_put(struct snd_kcontrol *kcontrol,
1555{ 1560{
1556 struct hda_codec *codec = snd_kcontrol_chip(kcontrol); 1561 struct hda_codec *codec = snd_kcontrol_chip(kcontrol);
1557 struct ad198x_spec *spec = codec->spec; 1562 struct ad198x_spec *spec = codec->spec;
1563 if (spec->need_dac_fix)
1564 spec->multiout.num_dacs = spec->multiout.max_channels / 2;
1558 return snd_hda_ch_mode_put(codec, ucontrol, spec->channel_mode, 1565 return snd_hda_ch_mode_put(codec, ucontrol, spec->channel_mode,
1559 spec->num_channel_mode, &spec->multiout.max_channels); 1566 spec->num_channel_mode, &spec->multiout.max_channels);
1560} 1567}