提交 7194cae6 编写于 作者: T Takashi Iwai

[ALSA] hda-codec - Fix dmics on ALC268 in auto configuration

Fixed the handling of dmics on ALC268 in the auto-configuration mode.
Signed-off-by: NTakashi Iwai <tiwai@suse.de>
上级 487145a1
...@@ -6258,16 +6258,21 @@ static void alc882_auto_init_analog_input(struct hda_codec *codec) ...@@ -6258,16 +6258,21 @@ static void alc882_auto_init_analog_input(struct hda_codec *codec)
for (i = 0; i < AUTO_PIN_LAST; i++) { for (i = 0; i < AUTO_PIN_LAST; i++) {
hda_nid_t nid = spec->autocfg.input_pins[i]; hda_nid_t nid = spec->autocfg.input_pins[i];
if (alc882_is_input_pin(nid)) { unsigned int vref;
snd_hda_codec_write(codec, nid, 0, if (!nid)
AC_VERB_SET_PIN_WIDGET_CONTROL, continue;
i <= AUTO_PIN_FRONT_MIC ? vref = PIN_IN;
PIN_VREF80 : PIN_IN); if (1 /*i <= AUTO_PIN_FRONT_MIC*/) {
if (nid != ALC882_PIN_CD_NID) if (snd_hda_param_read(codec, nid, AC_PAR_PIN_CAP) &
snd_hda_codec_write(codec, nid, 0, AC_PINCAP_VREF_80)
AC_VERB_SET_AMP_GAIN_MUTE, vref = PIN_VREF80;
AMP_OUT_MUTE);
} }
snd_hda_codec_write(codec, nid, 0,
AC_VERB_SET_PIN_WIDGET_CONTROL, vref);
if (get_wcaps(codec, nid) & AC_WCAP_OUT_AMP)
snd_hda_codec_write(codec, nid, 0,
AC_VERB_SET_AMP_GAIN_MUTE,
AMP_OUT_MUTE);
} }
} }
...@@ -10125,6 +10130,10 @@ static int alc268_auto_create_analog_input_ctls(struct alc_spec *spec, ...@@ -10125,6 +10130,10 @@ static int alc268_auto_create_analog_input_ctls(struct alc_spec *spec,
case 0x1c: case 0x1c:
idx1 = 3; /* CD */ idx1 = 3; /* CD */
break; break;
case 0x12:
case 0x13:
idx1 = 6; /* digital mics */
break;
default: default:
continue; continue;
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册