Lines Matching +full:headset +full:- +full:detect +full:- +full:gpios
1 // SPDX-License-Identifier: GPL-2.0-or-later
32 /* extra amp-initialization sequence types */
165 if (val != -1) in alc_update_coefex_idx()
176 struct alc_spec *spec = codec->spec; in alc_get_coef0()
178 if (!spec->coef0) in alc_get_coef0()
179 spec->coef0 = alc_read_coef_idx(codec, 0); in alc_get_coef0()
180 return spec->coef0; in alc_get_coef0()
193 #define WRITE_COEFEX(_nid, _idx, _val) UPDATE_COEFEX(_nid, _idx, -1, _val)
200 for (; fw->nid; fw++) { in alc_process_coef_fw()
201 if (fw->mask == (unsigned short)-1) in alc_process_coef_fw()
202 alc_write_coefex_idx(codec, fw->nid, fw->idx, fw->val); in alc_process_coef_fw()
204 alc_update_coefex_idx(codec, fw->nid, fw->idx, in alc_process_coef_fw()
205 fw->mask, fw->val); in alc_process_coef_fw()
216 struct alc_spec *spec = codec->spec; in alc_setup_gpio()
218 spec->gpio_mask |= mask; in alc_setup_gpio()
219 spec->gpio_dir |= mask; in alc_setup_gpio()
220 spec->gpio_data |= mask; in alc_setup_gpio()
225 struct alc_spec *spec = codec->spec; in alc_write_gpio_data()
228 spec->gpio_data); in alc_write_gpio_data()
234 struct alc_spec *spec = codec->spec; in alc_update_gpio_data()
235 unsigned int oldval = spec->gpio_data; in alc_update_gpio_data()
238 spec->gpio_data |= mask; in alc_update_gpio_data()
240 spec->gpio_data &= ~mask; in alc_update_gpio_data()
241 if (oldval != spec->gpio_data) in alc_update_gpio_data()
247 struct alc_spec *spec = codec->spec; in alc_write_gpio()
249 if (!spec->gpio_mask) in alc_write_gpio()
252 snd_hda_codec_write(codec, codec->core.afg, 0, in alc_write_gpio()
253 AC_VERB_SET_GPIO_MASK, spec->gpio_mask); in alc_write_gpio()
254 snd_hda_codec_write(codec, codec->core.afg, 0, in alc_write_gpio()
255 AC_VERB_SET_GPIO_DIRECTION, spec->gpio_dir); in alc_write_gpio()
256 if (spec->gpio_write_delay) in alc_write_gpio()
306 struct alc_spec *spec = codec->spec; in alc_fix_pll()
308 if (spec->pll_nid) in alc_fix_pll()
309 alc_update_coefex_idx(codec, spec->pll_nid, spec->pll_coef_idx, in alc_fix_pll()
310 1 << spec->pll_coef_bit, 0); in alc_fix_pll()
316 struct alc_spec *spec = codec->spec; in alc_fix_pll_init()
317 spec->pll_nid = nid; in alc_fix_pll_init()
318 spec->pll_coef_idx = coef_idx; in alc_fix_pll_init()
319 spec->pll_coef_bit = coef_bit; in alc_fix_pll_init()
323 /* update the master volume per volume-knob's unsol event */
337 val = snd_hda_codec_read(codec, jack->nid, 0, in alc_update_knob_master()
340 uctl->value.integer.value[0] = val; in alc_update_knob_master()
341 uctl->value.integer.value[1] = val; in alc_update_knob_master()
342 kctl->put(kctl, uctl); in alc_update_knob_master()
360 switch (codec->core.vendor_id) { in alc_fill_eapd_coef()
466 /* alc888-VA */ in alc888_coef_init()
468 /* alc888-VB */ in alc888_coef_init()
508 if (codec->bus->shutdown) in alc_headset_mic_no_shutup()
511 snd_array_for_each(&codec->init_pins, i, pin) { in alc_headset_mic_no_shutup()
513 if (pin->nid != mic_pin) in alc_headset_mic_no_shutup()
514 snd_hda_codec_read(codec, pin->nid, 0, in alc_headset_mic_no_shutup()
518 codec->pins_shutup = 1; in alc_headset_mic_no_shutup()
523 struct alc_spec *spec = codec->spec; in alc_shutup_pins()
525 switch (codec->core.vendor_id) { in alc_shutup_pins()
533 if (!spec->no_shutup_pins) in alc_shutup_pins()
540 * just turning off EAPD and a little pause for avoiding pop-noise
544 struct alc_spec *spec = codec->spec; in alc_eapd_shutup()
547 if (!spec->no_depop_delay) in alc_eapd_shutup()
559 switch (codec->core.vendor_id) { in alc_auto_init_amp()
580 if (spec->gen.autocfg.hp_pins[0]) in alc_get_hp_pin()
581 return spec->gen.autocfg.hp_pins[0]; in alc_get_hp_pin()
582 if (spec->gen.autocfg.line_out_type == AC_JACK_HP_OUT) in alc_get_hp_pin()
583 return spec->gen.autocfg.line_out_pins[0]; in alc_get_hp_pin()
591 /* Could be any non-zero and even value. When used as fixup, tells
599 struct alc_spec *spec = codec->spec; in alc_fixup_sku_ignore()
601 spec->cdefine.fixup = 1; in alc_fixup_sku_ignore()
602 spec->cdefine.sku_cfg = ALC_FIXUP_SKU_IGNORE; in alc_fixup_sku_ignore()
609 struct alc_spec *spec = codec->spec; in alc_fixup_no_depop_delay()
612 spec->no_depop_delay = 1; in alc_fixup_no_depop_delay()
613 codec->depop_delay = 0; in alc_fixup_no_depop_delay()
621 struct alc_spec *spec = codec->spec; in alc_auto_parse_customize_define()
623 spec->cdefine.enable_pcbeep = 1; /* assume always enabled */ in alc_auto_parse_customize_define()
625 if (spec->cdefine.fixup) { in alc_auto_parse_customize_define()
626 ass = spec->cdefine.sku_cfg; in alc_auto_parse_customize_define()
628 return -1; in alc_auto_parse_customize_define()
632 if (!codec->bus->pci) in alc_auto_parse_customize_define()
633 return -1; in alc_auto_parse_customize_define()
634 ass = codec->core.subsystem_id & 0xffff; in alc_auto_parse_customize_define()
635 if (ass != codec->bus->pci->subsystem_device && (ass & 1)) in alc_auto_parse_customize_define()
639 if (codec->core.vendor_id == 0x10ec0260) in alc_auto_parse_customize_define()
645 codec->core.chip_name, ass); in alc_auto_parse_customize_define()
646 return -1; in alc_auto_parse_customize_define()
656 return -1; in alc_auto_parse_customize_define()
658 spec->cdefine.port_connectivity = ass >> 30; in alc_auto_parse_customize_define()
659 spec->cdefine.enable_pcbeep = (ass & 0x100000) >> 20; in alc_auto_parse_customize_define()
660 spec->cdefine.check_sum = (ass >> 16) & 0xf; in alc_auto_parse_customize_define()
661 spec->cdefine.customization = ass >> 8; in alc_auto_parse_customize_define()
663 spec->cdefine.sku_cfg = ass; in alc_auto_parse_customize_define()
664 spec->cdefine.external_amp = (ass & 0x38) >> 3; in alc_auto_parse_customize_define()
665 spec->cdefine.platform_type = (ass & 0x4) >> 2; in alc_auto_parse_customize_define()
666 spec->cdefine.swap = (ass & 0x2) >> 1; in alc_auto_parse_customize_define()
667 spec->cdefine.override = ass & 0x1; in alc_auto_parse_customize_define()
670 nid, spec->cdefine.sku_cfg); in alc_auto_parse_customize_define()
672 spec->cdefine.port_connectivity); in alc_auto_parse_customize_define()
673 codec_dbg(codec, "SKU: enable_pcbeep=0x%x\n", spec->cdefine.enable_pcbeep); in alc_auto_parse_customize_define()
674 codec_dbg(codec, "SKU: check_sum=0x%08x\n", spec->cdefine.check_sum); in alc_auto_parse_customize_define()
675 codec_dbg(codec, "SKU: customization=0x%08x\n", spec->cdefine.customization); in alc_auto_parse_customize_define()
676 codec_dbg(codec, "SKU: external_amp=0x%x\n", spec->cdefine.external_amp); in alc_auto_parse_customize_define()
677 codec_dbg(codec, "SKU: platform_type=0x%x\n", spec->cdefine.platform_type); in alc_auto_parse_customize_define()
678 codec_dbg(codec, "SKU: swap=0x%x\n", spec->cdefine.swap); in alc_auto_parse_customize_define()
679 codec_dbg(codec, "SKU: override=0x%x\n", spec->cdefine.override); in alc_auto_parse_customize_define()
684 /* return the position of NID in the list, or -1 if not found */
691 return -1; in find_idx_in_nid_list()
699 /* check subsystem ID and set up device-specific initialization;
702 /* 32-bit subsystem ID for BIOS loading in HD Audio codec.
706 * port-A --> pin 39/41, port-E --> pin 14/15, port-D --> pin 35/36
712 struct alc_spec *spec = codec->spec; in alc_subsystem_id()
714 if (spec->cdefine.fixup) { in alc_subsystem_id()
715 ass = spec->cdefine.sku_cfg; in alc_subsystem_id()
721 ass = codec->core.subsystem_id & 0xffff; in alc_subsystem_id()
722 if (codec->bus->pci && in alc_subsystem_id()
723 ass != codec->bus->pci->subsystem_device && (ass & 1)) in alc_subsystem_id()
736 if (codec->core.vendor_id == 0x10ec0260) in alc_subsystem_id()
757 ass & 0xffff, codec->core.vendor_id); in alc_subsystem_id()
761 * 2 : 0 --> Desktop, 1 --> Laptop in alc_subsystem_id()
766 if (spec->init_amp == ALC_INIT_UNDEFINED) { in alc_subsystem_id()
779 spec->init_amp = ALC_INIT_DEFAULT; in alc_subsystem_id()
791 * 12~11: Headphone out -> 00: PortA, 01: PortE, 02: PortD, 03: Resvered in alc_subsystem_id()
793 * 15 : 1 --> enable the function "Mute internal speaker in alc_subsystem_id()
800 if (found_in_nid_list(nid, spec->gen.autocfg.line_out_pins, in alc_subsystem_id()
801 spec->gen.autocfg.line_outs)) in alc_subsystem_id()
803 spec->gen.autocfg.hp_pins[0] = nid; in alc_subsystem_id()
808 /* Check the validity of ALC subsystem-id
809 * ports contains an array of 4 pin NIDs for port-A, E, D and I */
813 struct alc_spec *spec = codec->spec; in alc_ssid_check()
814 if (spec->init_amp == ALC_INIT_UNDEFINED) { in alc_ssid_check()
817 spec->init_amp = ALC_INIT_DEFAULT; in alc_ssid_check()
828 struct alc_spec *spec = codec->spec; in alc_fixup_inv_dmic()
830 spec->gen.inv_dmic_split = 1; in alc_fixup_inv_dmic()
857 ((codec)->core.dev.power.power_state.event == PM_EVENT_RESUME)
859 ((codec)->core.dev.power.power_state.event == PM_EVENT_RESTORE)
863 struct alc_spec *spec = codec->spec; in alc_init()
869 if (spec->init_hook) in alc_init()
870 spec->init_hook(codec); in alc_init()
872 spec->gen.skip_verbs = 1; /* applied in below */ in alc_init()
875 alc_auto_init_amp(codec, spec->init_amp); in alc_init()
885 struct alc_spec *spec = codec->spec; in alc_shutup()
890 if (spec && spec->shutup) in alc_shutup()
891 spec->shutup(codec); in alc_shutup()
898 struct alc_spec *spec = codec->spec; in alc_reboot_notify()
900 if (spec && spec->reboot_notify) in alc_reboot_notify()
901 spec->reboot_notify(codec); in alc_reboot_notify()
916 struct alc_spec *spec = codec->spec; in alc_suspend()
918 if (spec && spec->power_hook) in alc_suspend()
919 spec->power_hook(codec); in alc_suspend()
927 struct alc_spec *spec = codec->spec; in alc_resume()
929 if (!spec->no_depop_delay) in alc_resume()
931 codec->patch_ops.init(codec); in alc_resume()
985 { 0x10ec0887, 0x00f0, 0x0030, "ALC887-VD" },
986 { 0x10ec0888, 0x00f0, 0x0030, "ALC888-VD" },
1031 for (p = rename_tbl; p->vendor_id; p++) { in alc_codec_rename_from_preset()
1032 if (p->vendor_id != codec->core.vendor_id) in alc_codec_rename_from_preset()
1034 if ((alc_get_coef0(codec) & p->coef_mask) == p->coef_bits) in alc_codec_rename_from_preset()
1035 return alc_codec_rename(codec, p->name); in alc_codec_rename_from_preset()
1038 if (!codec->bus->pci) in alc_codec_rename_from_preset()
1040 for (q = rename_pci_tbl; q->codec_vendor_id; q++) { in alc_codec_rename_from_preset()
1041 if (q->codec_vendor_id != codec->core.vendor_id) in alc_codec_rename_from_preset()
1043 if (q->pci_subvendor != codec->bus->pci->subsystem_vendor) in alc_codec_rename_from_preset()
1045 if (!q->pci_subdevice || in alc_codec_rename_from_preset()
1046 q->pci_subdevice == codec->bus->pci->subsystem_device) in alc_codec_rename_from_preset()
1047 return alc_codec_rename(codec, q->name); in alc_codec_rename_from_preset()
1055 * Digital-beep handlers
1074 knew = snd_hda_gen_add_kctl(&spec->gen, NULL, in set_beep_amp()
1077 return -ENOMEM; in set_beep_amp()
1078 knew->private_value = beep_amp; in set_beep_amp()
1091 SND_PCI_QUIRK(0x1458, 0xa002, "GA-MA790X", 1),
1093 /* denylist -- no beep available */
1101 struct alc_spec *spec = codec->spec; in has_cdefine_beep()
1103 q = snd_pci_quirk_lookup(codec->bus->pci, beep_allow_list); in has_cdefine_beep()
1105 return q->value; in has_cdefine_beep()
1106 return spec->cdefine.enable_pcbeep; in has_cdefine_beep()
1121 struct alc_spec *spec = codec->spec; in alc_parse_auto_config()
1122 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in alc_parse_auto_config()
1126 spec->parse_flags); in alc_parse_auto_config()
1147 return -ENOMEM; in alc_alloc_spec()
1148 codec->spec = spec; in alc_alloc_spec()
1149 snd_hda_gen_spec_init(&spec->gen); in alc_alloc_spec()
1150 spec->gen.mixer_nid = mixer_nid; in alc_alloc_spec()
1151 spec->gen.own_eapd_ctl = 1; in alc_alloc_spec()
1152 codec->single_adc_amp = 1; in alc_alloc_spec()
1154 codec->spdif_status_reset = 1; in alc_alloc_spec()
1155 codec->forced_resume = 1; in alc_alloc_spec()
1156 codec->patch_ops = alc_patch_ops; in alc_alloc_spec()
1174 * ALC880 fix-ups
1204 /* enable the volume-knob widget support on NID 0x21 */
1245 { 0x1a, 0x0181344f }, /* line-in */
1293 { 0x19, 0x01a19950 }, /* mic-in */
1313 { 0x19, 0x01a19950 }, /* mic-in */
1353 { 0x18, 0x01a19950 }, /* mic-in */
1355 { 0x1a, 0x01813031 }, /* line-in */
1386 { 0x14, 0x01014010 }, /* line-out */
1390 { 0x18, 0x01a19c30 }, /* mic-in */
1392 { 0x1a, 0x01813031 }, /* line-in */
1393 { 0x1b, 0x02a19c40 }, /* front-mic */
1426 { 0x18, 0x01a19c30 }, /* mic-in */
1428 { 0x1a, 0x01813031 }, /* line-in */
1429 { 0x1b, 0x02a19c40 }, /* front-mic */
1462 { 0x18, 0x01a19c30 }, /* mic-in */
1463 { 0x19, 0x02a19c40 }, /* front-mic */
1464 { 0x1a, 0x01813031 }, /* line-in */
1494 { 0x1b, 0x0121401f }, /* HP with jack detect */
1528 * It's not quite sure whether BIOS sets the correct pin-config table
1553 SND_PCI_QUIRK(0x1695, 0x4012, "EPox EP-5LDA", ALC880_FIXUP_5ST_DIG),
1568 SND_PCI_QUIRK(0xa0a0, 0x0560, "AOpen i915GMm-HFS", ALC880_FIXUP_5ST_DIG),
1575 {.id = ALC880_FIXUP_3ST_DIG, .name = "3stack-digout"},
1577 {.id = ALC880_FIXUP_5ST_DIG, .name = "5stack-digout"},
1579 {.id = ALC880_FIXUP_6ST_DIG, .name = "6stack-digout"},
1580 {.id = ALC880_FIXUP_6ST_AUTOMUTE, .name = "6stack-automute"},
1597 spec = codec->spec; in patch_alc880()
1598 spec->gen.need_dac_fix = 1; in patch_alc880()
1599 spec->gen.beep_nid = 0x01; in patch_alc880()
1601 codec->patch_ops.unsol_event = alc880_unsol_event; in patch_alc880()
1614 if (!spec->gen.no_analog) { in patch_alc880()
1659 struct alc_spec *spec = codec->spec; in alc260_gpio1_automute()
1661 alc_update_gpio_data(codec, 0x01, spec->gen.hp_jack_present); in alc260_gpio1_automute()
1667 struct alc_spec *spec = codec->spec; in alc260_fixup_gpio1_toggle()
1672 spec->gen.automute_hook = alc260_gpio1_automute; in alc260_fixup_gpio1_toggle()
1673 spec->gen.detect_hp = 1; in alc260_fixup_gpio1_toggle()
1674 spec->gen.automute_speaker = 1; in alc260_fixup_gpio1_toggle()
1675 spec->gen.autocfg.hp_pins[0] = 0x0f; /* copy it for automute */ in alc260_fixup_gpio1_toggle()
1685 struct alc_spec *spec = codec->spec; in alc260_fixup_kn1()
1705 spec->init_amp = ALC_INIT_NONE; in alc260_fixup_kn1()
1713 struct alc_spec *spec = codec->spec; in alc260_fixup_fsc_s7020()
1715 spec->init_amp = ALC_INIT_NONE; in alc260_fixup_fsc_s7020()
1721 struct alc_spec *spec = codec->spec; in alc260_fixup_fsc_s7020_jwse()
1723 spec->gen.add_jack_modes = 1; in alc260_fixup_fsc_s7020_jwse()
1724 spec->gen.hp_mic = 1; in alc260_fixup_fsc_s7020_jwse()
1831 {.id = ALC260_FIXUP_FSC_S7020_JWSE, .name = "fujitsu-jwse"},
1846 spec = codec->spec; in patch_alc260()
1851 spec->gen.prefer_hp_amp = 1; in patch_alc260()
1852 spec->gen.beep_nid = 0x01; in patch_alc260()
1854 spec->shutup = alc_eapd_shutup; in patch_alc260()
1867 if (!spec->gen.no_analog) { in patch_alc260()
1889 * 6-channel independent captures.
1891 * In addition, an independent DAC for the multi-playback (not used in this
1951 struct alc_spec *spec = codec->spec; in alc885_fixup_macpro_gpio()
1953 spec->gpio_write_delay = true; in alc885_fixup_macpro_gpio()
1987 struct alc_spec *spec = codec->spec; in alc889_fixup_mbp_vref()
1999 spec->gen.keep_vref_in_automute = 1; in alc889_fixup_mbp_vref()
2007 struct alc_spec *spec = codec->spec; in alc889_fixup_mac_pins()
2016 spec->gen.keep_vref_in_automute = 1; in alc889_fixup_mac_pins()
2051 * all-in-one desktop PCs (for example VGC-LN51JGB) through DAC 0x05
2056 struct alc_spec *spec = codec->spec; in alc882_fixup_no_primary_hp()
2058 spec->gen.no_primary_hp = 1; in alc882_fixup_no_primary_hp()
2059 spec->gen.no_multi_io = 1; in alc882_fixup_no_primary_hp()
2066 /* For dual-codec configuration, we need to disable some features to avoid
2072 struct alc_spec *spec = codec->spec; in alc_fixup_dual_codecs()
2077 spec->gen.suppress_vmaster = 1; in alc_fixup_dual_codecs()
2078 /* auto-mute and auto-mic switch don't work with multiple codecs */ in alc_fixup_dual_codecs()
2079 spec->gen.suppress_auto_mute = 1; in alc_fixup_dual_codecs()
2080 spec->gen.suppress_auto_mic = 1; in alc_fixup_dual_codecs()
2082 spec->gen.mixer_nid = 0; in alc_fixup_dual_codecs()
2084 codec->force_pin_prefix = 1; in alc_fixup_dual_codecs()
2094 strcpy(kctl->id.name, newname); in rename_ctl()
2105 strcpy(codec->card->longname, "HDAudio-Gigabyte-ALC1220DualCodecs"); in alc1220_fixup_gb_dual_codecs()
2110 codec->addr == 0 ? in alc1220_fixup_gb_dual_codecs()
2111 "Rear-Panel Capture Volume" : in alc1220_fixup_gb_dual_codecs()
2112 "Front-Panel Capture Volume"); in alc1220_fixup_gb_dual_codecs()
2114 codec->addr == 0 ? in alc1220_fixup_gb_dual_codecs()
2115 "Rear-Panel Capture Switch" : in alc1220_fixup_gb_dual_codecs()
2116 "Front-Panel Capture Switch"); in alc1220_fixup_gb_dual_codecs()
2152 struct alc_spec *spec = codec->spec; in alc887_asus_hp_automute_hook()
2157 if (spec->gen.hp_jack_present) in alc887_asus_hp_automute_hook()
2167 struct alc_spec *spec = codec->spec; in alc887_fixup_asus_jack()
2171 spec->gen.hp_automute_hook = alc887_asus_hp_automute_hook; in alc887_fixup_asus_jack()
2220 { 0x1b, 0x02214120 }, /* Front HP jack is flaky, disable jack detect */
2316 /* setting bits 1-5 disables DAC nids 0x02-0x06
2425 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
2434 { 0x15, 0x02a14150 }, /* use as headset mic, without its own jack detect */
2469 SND_PCI_QUIRK(0x1025, 0x0155, "Packard-Bell M5120", ALC882_FIXUP_PB_M5210),
2485 SND_PCI_QUIRK(0x104d, 0x9043, "Sony Vaio VGC-LN51JGB", ALC882_FIXUP_NO_PRIMARY_HP),
2513 SND_PCI_QUIRK(0x1458, 0xa002, "Gigabyte EP45-DS3/Z87X-UD3H", ALC889_FIXUP_FRONT_HP_NO_PRESENCE),
2514 SND_PCI_QUIRK(0x1458, 0xa0b8, "Gigabyte AZ370-Gaming", ALC1220_FIXUP_GB_DUAL_CODECS),
2517 SND_PCI_QUIRK(0x1462, 0x11f7, "MSI-GE63", ALC1220_FIXUP_CLEVO_P950),
2518 SND_PCI_QUIRK(0x1462, 0x1228, "MSI-GP63", ALC1220_FIXUP_CLEVO_P950),
2519 SND_PCI_QUIRK(0x1462, 0x1275, "MSI-GL63", ALC1220_FIXUP_CLEVO_P950),
2520 SND_PCI_QUIRK(0x1462, 0x1276, "MSI-GL73", ALC1220_FIXUP_CLEVO_P950),
2521 SND_PCI_QUIRK(0x1462, 0x1293, "MSI-GP65", ALC1220_FIXUP_CLEVO_P950),
2522 SND_PCI_QUIRK(0x1462, 0x7350, "MSI-7350", ALC889_FIXUP_CD),
2523 SND_PCI_QUIRK(0x1462, 0xda57, "MSI Z270-Gaming", ALC1220_FIXUP_GB_DUAL_CODECS),
2525 SND_PCI_QUIRK(0x147b, 0x107a, "Abit AW9D-MAX", ALC882_FIXUP_ABIT_AW9D_MAX),
2535 SND_PCI_QUIRK(0x1558, 0x96e1, "Clevo P960[ER][CDFN]-K", ALC1220_FIXUP_CLEVO_P950),
2537 SND_PCI_QUIRK(0x1558, 0x97e2, "Clevo P970RC-M", ALC1220_FIXUP_CLEVO_P950),
2554 {.id = ALC882_FIXUP_ABIT_AW9D_MAX, .name = "abit-aw9d"},
2555 {.id = ALC882_FIXUP_LENOVO_Y530, .name = "lenovo-y530"},
2556 {.id = ALC882_FIXUP_ACER_ASPIRE_7736, .name = "acer-aspire-7736"},
2557 {.id = ALC882_FIXUP_ASUS_W90V, .name = "asus-w90v"},
2559 {.id = ALC889_FIXUP_FRONT_HP_NO_PRESENCE, .name = "no-front-hp"},
2560 {.id = ALC889_FIXUP_VAIO_TT, .name = "vaio-tt"},
2562 {.id = ALC882_FIXUP_EAPD, .name = "alc882-eapd"},
2563 {.id = ALC883_FIXUP_EAPD, .name = "alc883-eapd"},
2567 {.id = ALC889_FIXUP_COEF, .name = "alc889-coef"},
2568 {.id = ALC882_FIXUP_ASUS_W2JC, .name = "asus-w2jc"},
2569 {.id = ALC882_FIXUP_ACER_ASPIRE_4930G, .name = "acer-aspire-4930g"},
2570 {.id = ALC882_FIXUP_ACER_ASPIRE_8930G, .name = "acer-aspire-8930g"},
2571 {.id = ALC883_FIXUP_ACER_EAPD, .name = "acer-aspire"},
2572 {.id = ALC885_FIXUP_MACPRO_GPIO, .name = "macpro-gpio"},
2573 {.id = ALC889_FIXUP_DAC_ROUTE, .name = "dac-route"},
2574 {.id = ALC889_FIXUP_MBP_VREF, .name = "mbp-vref"},
2575 {.id = ALC889_FIXUP_IMAC91_VREF, .name = "imac91-vref"},
2576 {.id = ALC889_FIXUP_MBA11_VREF, .name = "mba11-vref"},
2577 {.id = ALC889_FIXUP_MBA21_VREF, .name = "mba21-vref"},
2578 {.id = ALC889_FIXUP_MP11_VREF, .name = "mp11-vref"},
2579 {.id = ALC889_FIXUP_MP41_VREF, .name = "mp41-vref"},
2580 {.id = ALC882_FIXUP_INV_DMIC, .name = "inv-dmic"},
2581 {.id = ALC882_FIXUP_NO_PRIMARY_HP, .name = "no-primary-hp"},
2582 {.id = ALC887_FIXUP_ASUS_BASS, .name = "asus-bass"},
2583 {.id = ALC1220_FIXUP_GB_DUAL_CODECS, .name = "dual-codecs"},
2584 {.id = ALC1220_FIXUP_CLEVO_P950, .name = "clevo-p950"},
2610 spec = codec->spec; in patch_alc882()
2612 switch (codec->core.vendor_id) { in patch_alc882()
2634 spec->gen.beep_nid = 0x01; in patch_alc882()
2641 if (!spec->gen.no_analog && spec->gen.beep_nid) { in patch_alc882()
2759 SND_PCI_QUIRK(0x17ff, 0x058d, "Benq T31-16", ALC262_FIXUP_BENQ_T31),
2765 {.id = ALC262_FIXUP_INV_DMIC, .name = "inv-dmic"},
2766 {.id = ALC262_FIXUP_FSC_H270, .name = "fsc-h270"},
2767 {.id = ALC262_FIXUP_FSC_S7110, .name = "fsc-s7110"},
2768 {.id = ALC262_FIXUP_HP_Z200, .name = "hp-z200"},
2770 {.id = ALC262_FIXUP_LENOVO_3000, .name = "lenovo-3000"},
2772 {.id = ALC262_FIXUP_BENQ_T31, .name = "benq-t31"},
2788 spec = codec->spec; in patch_alc262()
2789 spec->gen.shared_mic_vref_pin = 0x18; in patch_alc262()
2791 spec->shutup = alc_eapd_shutup; in patch_alc262()
2795 * under-run in patch_alc262()
2810 spec->gen.beep_nid = 0x01; in patch_alc262()
2817 if (!spec->gen.no_analog && spec->gen.beep_nid) { in patch_alc262()
2843 mutex_lock(&codec->control_mutex); in alc268_beep_switch_put()
2844 pval = kcontrol->private_value; in alc268_beep_switch_put()
2845 kcontrol->private_value = (pval & ~0xff) | 0x0f; in alc268_beep_switch_put()
2848 kcontrol->private_value = (pval & ~0xff) | 0x10; in alc268_beep_switch_put()
2851 kcontrol->private_value = pval; in alc268_beep_switch_put()
2852 mutex_unlock(&codec->control_mutex); in alc268_beep_switch_put()
2905 {.id = ALC268_FIXUP_INV_DMIC, .name = "inv-dmic"},
2906 {.id = ALC268_FIXUP_HP_EAPD, .name = "hp-eapd"},
2937 /* ALC268 has no aa-loopback mixer */ in patch_alc268()
2942 spec = codec->spec; in patch_alc268()
2944 spec->gen.beep_nid = 0x01; in patch_alc268()
2946 spec->shutup = alc_eapd_shutup; in patch_alc268()
2958 if (err > 0 && !spec->gen.no_analog && in patch_alc268()
2959 spec->gen.autocfg.speaker_pins[0] != 0x1d) { in patch_alc268()
2961 if (!snd_hda_gen_add_kctl(&spec->gen, NULL, in patch_alc268()
2963 err = -ENOMEM; in patch_alc268()
2998 /* different alc269-variants */
3030 struct alc_spec *spec = codec->spec; in alc269_parse_auto_config()
3033 switch (spec->codec_variant) { in alc269_parse_auto_config()
3079 if (jack->unsol_res & (7 << 13)) in alc_headset_btn_callback()
3082 if (jack->unsol_res & (1 << 16 | 3 << 8)) in alc_headset_btn_callback()
3086 if (jack->unsol_res & (7 << 23)) in alc_headset_btn_callback()
3090 if (jack->unsol_res & (7 << 10)) in alc_headset_btn_callback()
3093 jack->jack->button_state = report; in alc_headset_btn_callback()
3098 struct alc_spec *spec = codec->spec; in alc_disable_headset_jack_key()
3100 if (!spec->has_hs_key) in alc_disable_headset_jack_key()
3103 switch (codec->core.vendor_id) { in alc_disable_headset_jack_key()
3124 struct alc_spec *spec = codec->spec; in alc_enable_headset_jack_key()
3126 if (!spec->has_hs_key) in alc_enable_headset_jack_key()
3129 switch (codec->core.vendor_id) { in alc_enable_headset_jack_key()
3151 struct alc_spec *spec = codec->spec; in alc_fixup_headset_jack()
3155 spec->has_hs_key = 1; in alc_fixup_headset_jack()
3158 snd_hda_jack_add_kctl(codec, 0x55, "Headset Jack", false, in alc_fixup_headset_jack()
3174 struct alc_spec *spec = codec->spec; in alc269_shutup()
3176 if (spec->codec_variant == ALC269_TYPE_ALC269VB) in alc269_shutup()
3178 if (spec->codec_variant == ALC269_TYPE_ALC269VB && in alc269_shutup()
3225 struct alc_spec *spec = codec->spec; in alc282_init()
3262 struct alc_spec *spec = codec->spec; in alc282_shutup()
3285 if (!spec->no_shutup_pins) in alc282_shutup()
3341 struct alc_spec *spec = codec->spec; in alc283_init()
3369 /* 3k pull low control for Headset jack. */ in alc283_init()
3377 struct alc_spec *spec = codec->spec; in alc283_shutup()
3399 if (!spec->no_shutup_pins) in alc283_shutup()
3414 struct alc_spec *spec = codec->spec; in alc256_init()
3429 if (spec->ultra_low_power) { in alc256_init()
3441 if (hp_pin_sense || spec->ultra_low_power) in alc256_init()
3447 if (hp_pin_sense || spec->ultra_low_power) in alc256_init()
3457 * Documentation/sound/hd-audio/realtek-pc-beep.rst for details of in alc256_init()
3465 struct alc_spec *spec = codec->spec; in alc256_shutup()
3480 if (hp_pin_sense || spec->ultra_low_power) in alc256_shutup()
3483 /* 3k pull low control for Headset jack. */ in alc256_shutup()
3486 * when booting with headset plugged. So skip setting it for the codec alc257 in alc256_shutup()
3488 if (codec->core.vendor_id != 0x10ec0257) in alc256_shutup()
3491 if (!spec->no_shutup_pins) in alc256_shutup()
3495 if (hp_pin_sense || spec->ultra_low_power) in alc256_shutup()
3500 if (spec->ultra_low_power) { in alc256_shutup()
3513 struct alc_spec *spec = codec->spec; in alc225_init()
3528 if (spec->ultra_low_power) { in alc225_init()
3535 if (hp1_pin_sense || spec->ultra_low_power) in alc225_init()
3542 if (hp1_pin_sense || hp2_pin_sense || spec->ultra_low_power) in alc225_init()
3545 if (hp1_pin_sense || spec->ultra_low_power) in alc225_init()
3552 if (hp1_pin_sense || hp2_pin_sense || spec->ultra_low_power) in alc225_init()
3561 struct alc_spec *spec = codec->spec; in alc225_shutup()
3569 /* 3k pull low control for Headset jack. */ in alc225_shutup()
3578 if (hp1_pin_sense || spec->ultra_low_power) in alc225_shutup()
3585 if (hp1_pin_sense || hp2_pin_sense || spec->ultra_low_power) in alc225_shutup()
3588 if (hp1_pin_sense || spec->ultra_low_power) in alc225_shutup()
3595 if (hp1_pin_sense || hp2_pin_sense || spec->ultra_low_power) in alc225_shutup()
3600 if (spec->ultra_low_power) { in alc225_shutup()
3615 struct alc_spec *spec = codec->spec; in alc_default_init()
3644 struct alc_spec *spec = codec->spec; in alc_default_shutup()
3664 if (!spec->no_shutup_pins) in alc_default_shutup()
3677 struct alc_spec *spec = codec->spec; in alc294_hp_init()
3689 if (!spec->no_shutup_pins) in alc294_hp_init()
3709 struct alc_spec *spec = codec->spec; in alc294_init()
3712 if (!spec->done_hp_init || in alc294_init()
3713 codec->core.dev.power.power_state.event == PM_EVENT_RESTORE) { in alc294_init()
3715 spec->done_hp_init = true; in alc294_init()
3815 struct alc_spec *spec = codec->spec; in alc269_suspend()
3817 if (spec->has_alc5505_dsp) in alc269_suspend()
3824 struct alc_spec *spec = codec->spec; in alc269_resume()
3826 if (spec->codec_variant == ALC269_TYPE_ALC269VB) in alc269_resume()
3828 if (spec->codec_variant == ALC269_TYPE_ALC269VB && in alc269_resume()
3833 codec->patch_ops.init(codec); in alc269_resume()
3835 if (spec->codec_variant == ALC269_TYPE_ALC269VB) in alc269_resume()
3837 if (spec->codec_variant == ALC269_TYPE_ALC269VB && in alc269_resume()
3849 if (spec->gpio_data) in alc269_resume()
3852 if (spec->has_alc5505_dsp) in alc269_resume()
3862 struct alc_spec *spec = codec->spec; in alc269_fixup_pincfg_no_hp_to_lineout()
3865 spec->parse_flags = HDA_PINCFG_NO_HP_FIXUP; in alc269_fixup_pincfg_no_hp_to_lineout()
3891 struct alc_spec *spec = codec->spec; in alc269_fixup_headset_mic()
3894 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc269_fixup_headset_mic()
3907 if (strcmp(codec->core.chip_name, "ALC271X") && in alc271_fixup_dmic()
3908 strcmp(codec->core.chip_name, "ALC269VB")) in alc271_fixup_dmic()
3918 struct alc_spec *spec = codec->spec; in alc269_fixup_pcm_44k()
3926 spec->gen.stream_analog_playback = &alc269_44k_pcm_analog_playback; in alc269_fixup_pcm_44k()
3927 spec->gen.stream_analog_capture = &alc269_44k_pcm_analog_capture; in alc269_fixup_pcm_44k()
3933 /* The digital-mic unit sends PDM (differential signal) instead of in alc269_fixup_stereo_dmic()
3953 struct alc_spec *spec = codec->spec; in alc269_fixup_quanta_mute()
3956 spec->gen.automute_hook = alc269_quanta_automute; in alc269_fixup_quanta_mute()
3962 struct alc_spec *spec = codec->spec; in alc269_x101_hp_automute_hook()
3967 vref = spec->gen.hp_jack_present ? PIN_VREF80 : 0; in alc269_x101_hp_automute_hook()
3996 alc_write_coef_idx(codec, 0x23, initval->value_0x23); in alc298_huawei_mbx_stereo_seq()
3998 if (initval->value_0x23 != 0x1e) in alc298_huawei_mbx_stereo_seq()
3999 alc_write_coef_idx(codec, 0x25, initval->value_0x25); in alc298_huawei_mbx_stereo_seq()
4038 for (seq = dac_init; seq->value_0x23; seq++) in alc298_fixup_huawei_mbx_stereo()
4045 struct alc_spec *spec = codec->spec; in alc269_fixup_x101_headset_mic()
4047 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc269_fixup_x101_headset_mic()
4048 spec->gen.hp_automute_hook = alc269_x101_hp_automute_hook; in alc269_fixup_x101_headset_mic()
4070 /* update mute-LED according to the speaker mute state via mic VREF pin */
4074 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in vref_mute_led_set()
4075 struct alc_spec *spec = codec->spec; in vref_mute_led_set()
4077 alc_update_vref_led(codec, spec->mute_led_nid, in vref_mute_led_set()
4078 spec->mute_led_polarity, brightness); in vref_mute_led_set()
4087 struct alc_spec *spec = codec->spec; in led_power_filter()
4090 (nid != spec->mute_led_nid && nid != spec->cap_mute_led_nid)) in led_power_filter()
4103 struct alc_spec *spec = codec->spec; in alc269_fixup_hp_mute_led()
4111 if (sscanf(dev->name, "HP_Mute_LED_%d_%x", &pol, &pin) != 2) in alc269_fixup_hp_mute_led()
4115 spec->mute_led_polarity = pol; in alc269_fixup_hp_mute_led()
4116 spec->mute_led_nid = pin - 0x0a + 0x18; in alc269_fixup_hp_mute_led()
4118 codec->power_filter = led_power_filter; in alc269_fixup_hp_mute_led()
4120 "Detected mute LED for %x:%d\n", spec->mute_led_nid, in alc269_fixup_hp_mute_led()
4121 spec->mute_led_polarity); in alc269_fixup_hp_mute_led()
4130 struct alc_spec *spec = codec->spec; in alc269_fixup_hp_mute_led_micx()
4133 spec->mute_led_polarity = 0; in alc269_fixup_hp_mute_led_micx()
4134 spec->mute_led_nid = pin; in alc269_fixup_hp_mute_led_micx()
4136 codec->power_filter = led_power_filter; in alc269_fixup_hp_mute_led_micx()
4164 alc_update_gpio_data(codec, mask, !enabled); /* muted -> LED on */ in alc_update_gpio_led()
4171 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in gpio_mute_led_set()
4172 struct alc_spec *spec = codec->spec; in gpio_mute_led_set()
4174 alc_update_gpio_led(codec, spec->gpio_mute_led_mask, in gpio_mute_led_set()
4175 spec->mute_led_polarity, !brightness); in gpio_mute_led_set()
4179 /* turn on/off mic-mute LED via GPIO per capture hook */
4183 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in micmute_led_set()
4184 struct alc_spec *spec = codec->spec; in micmute_led_set()
4186 alc_update_gpio_led(codec, spec->gpio_mic_led_mask, in micmute_led_set()
4187 spec->micmute_led_polarity, !brightness); in micmute_led_set()
4191 /* setup mute and mic-mute GPIO bits, add hooks appropriately */
4197 struct alc_spec *spec = codec->spec; in alc_fixup_hp_gpio_led()
4204 spec->gpio_mute_led_mask = mute_mask; in alc_fixup_hp_gpio_led()
4208 spec->gpio_mic_led_mask = micmute_mask; in alc_fixup_hp_gpio_led()
4237 /* turn on/off mic-mute LED per capture hook via VREF change */
4241 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in vref_micmute_led_set()
4242 struct alc_spec *spec = codec->spec; in vref_micmute_led_set()
4244 alc_update_vref_led(codec, spec->cap_mute_led_nid, in vref_micmute_led_set()
4245 spec->micmute_led_polarity, brightness); in vref_micmute_led_set()
4252 struct alc_spec *spec = codec->spec; in alc269_fixup_hp_gpio_mic1_led()
4259 spec->gpio_mask |= 0x10; in alc269_fixup_hp_gpio_mic1_led()
4260 spec->gpio_dir |= 0x10; in alc269_fixup_hp_gpio_mic1_led()
4261 spec->cap_mute_led_nid = 0x18; in alc269_fixup_hp_gpio_mic1_led()
4263 codec->power_filter = led_power_filter; in alc269_fixup_hp_gpio_mic1_led()
4270 struct alc_spec *spec = codec->spec; in alc280_fixup_hp_gpio4()
4274 spec->cap_mute_led_nid = 0x18; in alc280_fixup_hp_gpio4()
4276 codec->power_filter = led_power_filter; in alc280_fixup_hp_gpio4()
4287 alc_update_coef_idx(codec, led->idx, led->mask, in alc_update_coef_led()
4288 on ? led->on : led->off); in alc_update_coef_led()
4291 /* update mute-LED according to the speaker mute state via COEF bit */
4295 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in coef_mute_led_set()
4296 struct alc_spec *spec = codec->spec; in coef_mute_led_set()
4298 alc_update_coef_led(codec, &spec->mute_led_coef, in coef_mute_led_set()
4299 spec->mute_led_polarity, brightness); in coef_mute_led_set()
4307 struct alc_spec *spec = codec->spec; in alc285_fixup_hp_mute_led_coefbit()
4310 spec->mute_led_polarity = 0; in alc285_fixup_hp_mute_led_coefbit()
4311 spec->mute_led_coef.idx = 0x0b; in alc285_fixup_hp_mute_led_coefbit()
4312 spec->mute_led_coef.mask = 1 << 3; in alc285_fixup_hp_mute_led_coefbit()
4313 spec->mute_led_coef.on = 1 << 3; in alc285_fixup_hp_mute_led_coefbit()
4314 spec->mute_led_coef.off = 0; in alc285_fixup_hp_mute_led_coefbit()
4323 struct alc_spec *spec = codec->spec; in alc236_fixup_hp_mute_led_coefbit()
4326 spec->mute_led_polarity = 0; in alc236_fixup_hp_mute_led_coefbit()
4327 spec->mute_led_coef.idx = 0x34; in alc236_fixup_hp_mute_led_coefbit()
4328 spec->mute_led_coef.mask = 1 << 5; in alc236_fixup_hp_mute_led_coefbit()
4329 spec->mute_led_coef.on = 0; in alc236_fixup_hp_mute_led_coefbit()
4330 spec->mute_led_coef.off = 1 << 5; in alc236_fixup_hp_mute_led_coefbit()
4335 /* turn on/off mic-mute LED per capture hook by coef bit */
4339 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in coef_micmute_led_set()
4340 struct alc_spec *spec = codec->spec; in coef_micmute_led_set()
4342 alc_update_coef_led(codec, &spec->mic_led_coef, in coef_micmute_led_set()
4343 spec->micmute_led_polarity, brightness); in coef_micmute_led_set()
4350 struct alc_spec *spec = codec->spec; in alc285_fixup_hp_coef_micmute_led()
4353 spec->mic_led_coef.idx = 0x19; in alc285_fixup_hp_coef_micmute_led()
4354 spec->mic_led_coef.mask = 1 << 13; in alc285_fixup_hp_coef_micmute_led()
4355 spec->mic_led_coef.on = 1 << 13; in alc285_fixup_hp_coef_micmute_led()
4356 spec->mic_led_coef.off = 0; in alc285_fixup_hp_coef_micmute_led()
4364 struct alc_spec *spec = codec->spec; in alc236_fixup_hp_coef_micmute_led()
4367 spec->mic_led_coef.idx = 0x35; in alc236_fixup_hp_coef_micmute_led()
4368 spec->mic_led_coef.mask = 3 << 2; in alc236_fixup_hp_coef_micmute_led()
4369 spec->mic_led_coef.on = 2 << 2; in alc236_fixup_hp_coef_micmute_led()
4370 spec->mic_led_coef.off = 1 << 2; in alc236_fixup_hp_coef_micmute_led()
4393 struct alc_spec *spec = codec->spec; in gpio2_mic_hotkey_event()
4397 input_report_key(spec->kb_dev, spec->alc_mute_keycode_map[ALC_KEY_MICMUTE_INDEX], 1); in gpio2_mic_hotkey_event()
4398 input_sync(spec->kb_dev); in gpio2_mic_hotkey_event()
4399 input_report_key(spec->kb_dev, spec->alc_mute_keycode_map[ALC_KEY_MICMUTE_INDEX], 0); in gpio2_mic_hotkey_event()
4400 input_sync(spec->kb_dev); in gpio2_mic_hotkey_event()
4405 struct alc_spec *spec = codec->spec; in alc_register_micmute_input_device()
4408 spec->kb_dev = input_allocate_device(); in alc_register_micmute_input_device()
4409 if (!spec->kb_dev) { in alc_register_micmute_input_device()
4411 return -ENOMEM; in alc_register_micmute_input_device()
4414 spec->alc_mute_keycode_map[ALC_KEY_MICMUTE_INDEX] = KEY_MICMUTE; in alc_register_micmute_input_device()
4416 spec->kb_dev->name = "Microphone Mute Button"; in alc_register_micmute_input_device()
4417 spec->kb_dev->evbit[0] = BIT_MASK(EV_KEY); in alc_register_micmute_input_device()
4418 spec->kb_dev->keycodesize = sizeof(spec->alc_mute_keycode_map[0]); in alc_register_micmute_input_device()
4419 spec->kb_dev->keycodemax = ARRAY_SIZE(spec->alc_mute_keycode_map); in alc_register_micmute_input_device()
4420 spec->kb_dev->keycode = spec->alc_mute_keycode_map; in alc_register_micmute_input_device()
4421 for (i = 0; i < ARRAY_SIZE(spec->alc_mute_keycode_map); i++) in alc_register_micmute_input_device()
4422 set_bit(spec->alc_mute_keycode_map[i], spec->kb_dev->keybit); in alc_register_micmute_input_device()
4424 if (input_register_device(spec->kb_dev)) { in alc_register_micmute_input_device()
4426 input_free_device(spec->kb_dev); in alc_register_micmute_input_device()
4427 spec->kb_dev = NULL; in alc_register_micmute_input_device()
4428 return -ENOMEM; in alc_register_micmute_input_device()
4442 struct alc_spec *spec = codec->spec; in alc280_fixup_hp_gpio2_mic_hotkey()
4446 spec->init_amp = ALC_INIT_DEFAULT; in alc280_fixup_hp_gpio2_mic_hotkey()
4450 spec->gpio_mask |= 0x06; in alc280_fixup_hp_gpio2_mic_hotkey()
4451 spec->gpio_dir |= 0x02; in alc280_fixup_hp_gpio2_mic_hotkey()
4452 spec->gpio_data |= 0x02; in alc280_fixup_hp_gpio2_mic_hotkey()
4453 snd_hda_codec_write_cache(codec, codec->core.afg, 0, in alc280_fixup_hp_gpio2_mic_hotkey()
4455 snd_hda_jack_detect_enable_callback(codec, codec->core.afg, in alc280_fixup_hp_gpio2_mic_hotkey()
4460 if (!spec->kb_dev) in alc280_fixup_hp_gpio2_mic_hotkey()
4465 input_unregister_device(spec->kb_dev); in alc280_fixup_hp_gpio2_mic_hotkey()
4466 spec->kb_dev = NULL; in alc280_fixup_hp_gpio2_mic_hotkey()
4476 struct alc_spec *spec = codec->spec; in alc233_fixup_lenovo_line2_mic_hotkey()
4480 spec->init_amp = ALC_INIT_DEFAULT; in alc233_fixup_lenovo_line2_mic_hotkey()
4489 if (!spec->kb_dev) in alc233_fixup_lenovo_line2_mic_hotkey()
4494 input_unregister_device(spec->kb_dev); in alc233_fixup_lenovo_line2_mic_hotkey()
4495 spec->kb_dev = NULL; in alc233_fixup_lenovo_line2_mic_hotkey()
4506 struct alc_spec *spec = codec->spec; in alc269_fixup_hp_line1_mic1_led()
4510 spec->cap_mute_led_nid = 0x18; in alc269_fixup_hp_line1_mic1_led()
4528 struct alc_spec *spec = codec->spec; in alc_headset_mode_unplugged()
4578 UPDATE_COEF(0x1a, 1<<3, 1<<3), /* Combo JD gating with LINE1-VREFO */ in alc_headset_mode_unplugged()
4580 UPDATE_COEF(0x4a, 0x000f, 0x000e), /* Combo Jack auto detect */ in alc_headset_mode_unplugged()
4603 if (spec->no_internal_mic_pin) { in alc_headset_mode_unplugged()
4608 switch (codec->core.vendor_id) { in alc_headset_mode_unplugged()
4655 codec_dbg(codec, "Headset jack set to unplugged mode.\n"); in alc_headset_mode_unplugged()
4697 UPDATE_COEF(0x1a, 1<<3, 0), /* Combo JD gating without LINE1-VREFO */ in alc_headset_mode_mic_in()
4719 switch (codec->core.vendor_id) { in alc_headset_mode_mic_in()
4793 codec_dbg(codec, "Headset jack set to mic-in mode.\n"); in alc_headset_mode_mic_in()
4843 UPDATE_COEF(0x4a, 0x000f, 0x000e), /* Combo Jack auto detect */ in alc_headset_mode_default()
4845 UPDATE_COEF(0x1a, 1<<3, 0), /* Combo JD gating without LINE1-VREFO */ in alc_headset_mode_default()
4862 switch (codec->core.vendor_id) { in alc_headset_mode_default()
4909 codec_dbg(codec, "Headset jack set to headphone (default) mode.\n"); in alc_headset_mode_default()
4969 switch (codec->core.vendor_id) { in alc_headset_mode_ctia()
5029 codec_dbg(codec, "Headset jack set to iPhone-style headset mode.\n"); in alc_headset_mode_ctia()
5082 switch (codec->core.vendor_id) { in alc_headset_mode_omtp()
5100 alc_update_coef_idx(codec, 0x8e, 0x0070, 0x0010);/* Headset output enable */ in alc_headset_mode_omtp()
5128 codec_dbg(codec, "Headset jack set to Nokia-style headset mode.\n"); in alc_headset_mode_omtp()
5135 struct alc_spec *spec = codec->spec; in alc_determine_headset_type()
5155 UPDATE_COEF(0x4a, 0x000f, 0x0008), /* Combo Jack auto detect */ in alc_determine_headset_type()
5174 if (spec->no_internal_mic_pin) { in alc_determine_headset_type()
5179 switch (codec->core.vendor_id) { in alc_determine_headset_type()
5324 codec_dbg(codec, "Headset jack detected iPhone-style headset: %s\n", in alc_determine_headset_type()
5326 spec->current_headset_type = is_ctia ? ALC_HEADSET_TYPE_CTIA : ALC_HEADSET_TYPE_OMTP; in alc_determine_headset_type()
5331 struct alc_spec *spec = codec->spec; in alc_update_headset_mode()
5333 hda_nid_t mux_pin = spec->gen.imux_pins[spec->gen.cur_mux[0]]; in alc_update_headset_mode()
5340 else if (mux_pin == spec->headset_mic_pin) in alc_update_headset_mode()
5342 else if (mux_pin == spec->headphone_mic_pin) in alc_update_headset_mode()
5347 if (new_headset_mode == spec->current_headset_mode) { in alc_update_headset_mode()
5355 spec->current_headset_mode = ALC_HEADSET_MODE_UNKNOWN; in alc_update_headset_mode()
5356 spec->current_headset_type = ALC_HEADSET_TYPE_UNKNOWN; in alc_update_headset_mode()
5357 spec->gen.hp_jack_present = false; in alc_update_headset_mode()
5360 if (spec->current_headset_type == ALC_HEADSET_TYPE_UNKNOWN) in alc_update_headset_mode()
5362 if (spec->current_headset_type == ALC_HEADSET_TYPE_CTIA) in alc_update_headset_mode()
5364 else if (spec->current_headset_type == ALC_HEADSET_TYPE_OMTP) in alc_update_headset_mode()
5366 spec->gen.hp_jack_present = true; in alc_update_headset_mode()
5369 alc_headset_mode_mic_in(codec, hp_pin, spec->headphone_mic_pin); in alc_update_headset_mode()
5370 spec->gen.hp_jack_present = false; in alc_update_headset_mode()
5374 spec->gen.hp_jack_present = true; in alc_update_headset_mode()
5380 if (spec->headphone_mic_pin && spec->headphone_mic_pin != hp_pin) in alc_update_headset_mode()
5381 snd_hda_set_pin_ctl_cache(codec, spec->headphone_mic_pin, in alc_update_headset_mode()
5384 spec->current_headset_mode = new_headset_mode; in alc_update_headset_mode()
5405 struct alc_spec *spec = codec->spec; in alc_probe_headset_mode()
5406 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in alc_probe_headset_mode()
5409 for (i = 0; i < cfg->num_inputs; i++) { in alc_probe_headset_mode()
5410 if (cfg->inputs[i].is_headset_mic && !spec->headset_mic_pin) in alc_probe_headset_mode()
5411 spec->headset_mic_pin = cfg->inputs[i].pin; in alc_probe_headset_mode()
5412 if (cfg->inputs[i].is_headphone_mic && !spec->headphone_mic_pin) in alc_probe_headset_mode()
5413 spec->headphone_mic_pin = cfg->inputs[i].pin; in alc_probe_headset_mode()
5416 WARN_ON(spec->gen.cap_sync_hook); in alc_probe_headset_mode()
5417 spec->gen.cap_sync_hook = alc_update_headset_mode_hook; in alc_probe_headset_mode()
5418 spec->gen.automute_hook = alc_update_headset_mode; in alc_probe_headset_mode()
5419 spec->gen.hp_automute_hook = alc_update_headset_jack_cb; in alc_probe_headset_mode()
5425 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode()
5429 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC | HDA_PINCFG_HEADPHONE_MIC; in alc_fixup_headset_mode()
5436 spec->current_headset_mode = ALC_HEADSET_MODE_UNKNOWN; in alc_fixup_headset_mode()
5437 spec->current_headset_type = ALC_HEADSET_TYPE_UNKNOWN; in alc_fixup_headset_mode()
5448 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode_no_hp_mic()
5449 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc_fixup_headset_mode_no_hp_mic()
5474 switch (codec->core.vendor_id) { in alc255_set_default_jack_type()
5499 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode_alc255_no_hp_mic()
5500 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc_fixup_headset_mode_alc255_no_hp_mic()
5510 struct alc_spec *spec = codec->spec; in alc288_update_headset_jack_cb()
5513 /* Headset Mic enable or disable, only for Dell Dino */ in alc288_update_headset_jack_cb()
5514 alc_update_gpio_data(codec, 0x40, spec->gen.hp_jack_present); in alc288_update_headset_jack_cb()
5522 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode_dell_alc288()
5524 spec->gpio_mask |= 0x40; in alc_fixup_headset_mode_dell_alc288()
5525 spec->gpio_dir |= 0x40; in alc_fixup_headset_mode_dell_alc288()
5526 spec->gen.hp_automute_hook = alc288_update_headset_jack_cb; in alc_fixup_headset_mode_dell_alc288()
5534 struct alc_spec *spec = codec->spec; in alc_fixup_auto_mute_via_amp()
5535 spec->gen.auto_mute_via_amp = 1; in alc_fixup_auto_mute_via_amp()
5543 struct alc_spec *spec = codec->spec; in alc_fixup_no_shutup()
5544 spec->no_shutup_pins = 1; in alc_fixup_no_shutup()
5552 struct alc_spec *spec = codec->spec; in alc_fixup_disable_aamix()
5553 /* Disable AA-loopback as it causes white noise */ in alc_fixup_disable_aamix()
5554 spec->gen.mixer_nid = 0; in alc_fixup_disable_aamix()
5567 struct alc_spec *spec = codec->spec; in alc_fixup_tpt440_dock()
5570 spec->reboot_notify = snd_hda_gen_reboot_notify; /* reduce noise */ in alc_fixup_tpt440_dock()
5571 spec->parse_flags = HDA_PINCFG_NO_HP_FIXUP; in alc_fixup_tpt440_dock()
5572 codec->power_save_node = 0; /* avoid click noises */ in alc_fixup_tpt440_dock()
5585 struct alc_spec *spec = codec->spec; in alc_fixup_tpt470_dock()
5588 spec->parse_flags = HDA_PINCFG_NO_HP_FIXUP; in alc_fixup_tpt470_dock()
5611 struct alc_spec *spec = codec->spec; in alc_fixup_tpt470_dacs()
5614 spec->gen.preferred_dacs = preferred_pairs; in alc_fixup_tpt470_dacs()
5619 struct alc_spec *spec = codec->spec; in alc_shutup_dell_xps13()
5631 struct alc_spec *spec = codec->spec; in alc_fixup_dell_xps13()
5632 struct hda_input_mux *imux = &spec->gen.input_mux; in alc_fixup_dell_xps13()
5637 /* mic pin 0x19 must be initialized with Vref Hi-Z, otherwise in alc_fixup_dell_xps13()
5641 spec->shutup = alc_shutup_dell_xps13; in alc_fixup_dell_xps13()
5645 for (i = 0; i < imux->num_items; i++) { in alc_fixup_dell_xps13()
5646 if (spec->gen.imux_pins[i] == 0x12) { in alc_fixup_dell_xps13()
5647 spec->gen.cur_mux[0] = i; in alc_fixup_dell_xps13()
5658 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode_alc662()
5661 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc_fixup_headset_mode_alc662()
5662 spec->gen.hp_mic = 1; /* Mic-in is same pin as headphone */ in alc_fixup_headset_mode_alc662()
5664 /* Disable boost for mic-in permanently. (This code is only called in alc_fixup_headset_mode_alc662()
5686 struct alc_spec *spec = codec->spec; in find_ext_mic_pin()
5687 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in find_ext_mic_pin()
5692 for (i = 0; i < cfg->num_inputs; i++) { in find_ext_mic_pin()
5693 if (cfg->inputs[i].type != AUTO_PIN_MIC) in find_ext_mic_pin()
5695 nid = cfg->inputs[i].pin; in find_ext_mic_pin()
5709 struct alc_spec *spec = codec->spec; in alc271_hp_gate_mic_jack()
5725 struct alc_spec *spec = codec->spec; in alc269_fixup_limit_int_mic_boost()
5726 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in alc269_fixup_limit_int_mic_boost()
5736 for (i = 0; i < cfg->num_inputs; i++) { in alc269_fixup_limit_int_mic_boost()
5737 hda_nid_t nid = cfg->inputs[i].pin; in alc269_fixup_limit_int_mic_boost()
5739 if (cfg->inputs[i].type != AUTO_PIN_MIC) in alc269_fixup_limit_int_mic_boost()
5756 struct alc_spec *spec = codec->spec; in alc283_hp_automute_hook()
5762 vref = spec->gen.hp_jack_present ? PIN_VREF80 : 0; in alc283_hp_automute_hook()
5772 struct alc_spec *spec = codec->spec; in alc283_fixup_chromebook()
5777 /* Disable AA-loopback as it causes white noise */ in alc283_fixup_chromebook()
5778 spec->gen.mixer_nid = 0; in alc283_fixup_chromebook()
5781 /* MIC2-VREF control */ in alc283_fixup_chromebook()
5793 struct alc_spec *spec = codec->spec; in alc283_fixup_sense_combo_jack()
5797 spec->gen.hp_automute_hook = alc283_hp_automute_hook; in alc283_fixup_sense_combo_jack()
5800 /* MIC2-VREF control */ in alc283_fixup_sense_combo_jack()
5810 struct alc_spec *spec = codec->spec; in asus_tx300_automute()
5813 spec->gen.mute_bits |= (1ULL << 0x14); in asus_tx300_automute()
5819 struct alc_spec *spec = codec->spec; in alc282_fixup_asus_tx300()
5827 spec->init_amp = ALC_INIT_DEFAULT; in alc282_fixup_asus_tx300()
5831 spec->gen.auto_mute_via_amp = 1; in alc282_fixup_asus_tx300()
5832 spec->gen.automute_hook = asus_tx300_automute; in alc282_fixup_asus_tx300()
5837 spec->init_amp = ALC_INIT_DEFAULT; in alc282_fixup_asus_tx300()
5870 Amp-out capability. we change the speaker's route to: in alc298_fixup_speaker_volume()
5871 Node 0x02 (Audio Output) -> Node 0x0c (Audio Mixer) -> Node 0x17 ( in alc298_fixup_speaker_volume()
5872 Pin Complex), since Node 0x02 has Amp-out caps, we can adjust in alc298_fixup_speaker_volume()
5904 struct alc_spec *spec = codec->spec; in alc280_hp_gpio4_automute_hook()
5908 alc_update_gpio_led(codec, 0x10, spec->mute_led_polarity, in alc280_hp_gpio4_automute_hook()
5909 !spec->gen.hp_jack_present); in alc280_hp_gpio4_automute_hook()
5912 /* Manage GPIOs for HP EliteBook Folio 9480m.
5922 struct alc_spec *spec = codec->spec; in alc280_fixup_hp_9480m()
5927 spec->gpio_mask |= 0x10; in alc280_fixup_hp_9480m()
5928 spec->gpio_dir |= 0x10; in alc280_fixup_hp_9480m()
5929 spec->gen.hp_automute_hook = alc280_hp_gpio4_automute_hook; in alc280_fixup_hp_9480m()
5937 struct alc_spec *spec = codec->spec; in alc275_fixup_gpio4_off()
5940 spec->gpio_mask |= 0x04; in alc275_fixup_gpio4_off()
5941 spec->gpio_dir |= 0x04; in alc275_fixup_gpio4_off()
5948 * DAC1 (NID 0x02) -> Speaker (NID 0x14); some eq applied secretly
5949 * DAC2 (NID 0x03) -> Bass (NID 0x17) & Headphone (NID 0x21); sharing a DAC
5950 * DAC3 (NID 0x06) -> Unused, due to the lack of volume amp
5959 struct alc_spec *spec = codec->spec; in alc285_fixup_thinkpad_x1_gen7()
5964 spec->gen.preferred_dacs = preferred_pairs; in alc285_fixup_thinkpad_x1_gen7()
5987 strcpy(codec->card->longname, "HDAudio-Lenovo-DualCodecs"); in alc233_alc662_fixup_lenovo_dual_codecs()
5992 codec->addr == 0 ? in alc233_alc662_fixup_lenovo_dual_codecs()
5993 "Rear-Panel Capture Volume" : in alc233_alc662_fixup_lenovo_dual_codecs()
5994 "Front-Panel Capture Volume"); in alc233_alc662_fixup_lenovo_dual_codecs()
5996 codec->addr == 0 ? in alc233_alc662_fixup_lenovo_dual_codecs()
5997 "Rear-Panel Capture Switch" : in alc233_alc662_fixup_lenovo_dual_codecs()
5998 "Front-Panel Capture Switch"); in alc233_alc662_fixup_lenovo_dual_codecs()
6009 codec->power_save_node = 1; in alc225_fixup_s3_pop_noise()
6016 struct alc_spec *spec = codec->spec; in alc274_fixup_bind_dacs()
6025 spec->gen.preferred_dacs = preferred_pairs; in alc274_fixup_bind_dacs()
6026 spec->gen.auto_mute_via_amp = 1; in alc274_fixup_bind_dacs()
6027 codec->power_save_node = 0; in alc274_fixup_bind_dacs()
6037 struct alc_spec *spec = codec->spec; in alc289_fixup_asus_ga401()
6040 spec->gen.preferred_dacs = preferred_pairs; in alc289_fixup_asus_ga401()
6041 spec->gen.obey_preferred_dacs = 1; in alc289_fixup_asus_ga401()
6057 switch (codec->core.vendor_id) { in alc_combo_jack_hp_jd_restart()
6079 struct alc_spec *spec = codec->spec; in alc295_fixup_chromebook()
6083 spec->ultra_low_power = true; in alc295_fixup_chromebook()
6114 /* Pin 0x21: headphones/headset mic */ in alc294_fixup_gx502_hp()
6155 struct alc_spec *spec = codec->spec; in alc_fixup_no_int_mic()
6161 spec->no_internal_mic_pin = true; in alc_fixup_no_int_mic()
6453 { 0x1a, 0x2101103f }, /* dock line-out */
6454 { 0x1b, 0x23a11040 }, /* dock mic-in */
6463 { 0x19, 0x01a1903c }, /* headset mic, with jack detect */
6488 { 0x19, 0x99a3092f }, /* int-mic */
6495 { 0x12, 0x99a3092f }, /* int-mic */
6507 { 0x19, 0x99a3092f }, /* int-mic */
6515 { 0x12, 0x99a3092f }, /* int-mic */
6585 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
6586 { 0x1a, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
6597 { 0x1a, 0x01a1913c }, /* use as headset mic, without its own jack detect */
6606 { 0x1a, 0x01a1913c }, /* use as headset mic, without its own jack detect */
6615 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
6616 { 0x1b, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
6635 { 0x19, 0x01a1913c }, /* headset mic w/o jack detect */
6644 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
6692 { 0x18, 0x04a1182c }, /* Headset mic */
6703 { 0x1b, 0x99a7012f }, /* int-mic */
6723 { 0x12, 0x99a3092f }, /* int-mic */
6748 /* class-D output amp +5dB */
6765 { 0x12, 0x99a3092f }, /* int-mic */
6838 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
6847 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
6856 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
6857 { 0x1a, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
6866 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
6885 { 0x18, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
6886 { 0x1a, 0x01a1913c }, /* use as headset mic, without its own jack detect */
6946 { 0x1b, 0x21011020 }, /* line-out */
6947 { 0x1a, 0x01a1903c }, /* headset mic */
6948 { 0x18, 0x2181103f }, /* line-in */
6957 { 0x1b, 0x21011020 }, /* line-out */
6958 { 0x18, 0x2181103f }, /* line-in */
6977 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
6978 { 0x1a, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
7024 { 0x18, 0x01a1913c }, /* headset mic w/o jack detect */
7033 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
7034 { 0x1a, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
7043 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
7085 /* Disable pass-through path for FRONT 14h */
7146 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
7147 { 0x1a, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
7161 { 0x19, 0x04a11120 }, /* use as headset mic, without its own jack detect */
7175 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
7223 { 0x16, 0x0101102f }, /* Rear Headset HP */
7224 { 0x19, 0x02a1913c }, /* use as Front headset mic, without its own jack detect */
7225 { 0x1a, 0x01a19030 }, /* Rear Headset MIC */
7292 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
7326 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
7336 { 0x19, 0x04a11120 }, /* use as headset mic, without its own jack detect */
7345 { 0x19, 0x01a1103c }, /* use as headset mic */
7377 { 0x1a, 0x01a1913c }, /* use as headset mic, without its own jack detect */
7386 /* Disable PCBEEP-IN passthrough */
7408 { 0x19, 0x01a1913c }, /* use as Front headset mic, without its own jack detect */
7439 { 0x19, 0x03a11020 }, /* headset mic with jack detect */
7448 { 0x19, 0x04a11120 }, /* use as headset mic, without its own jack detect */
7457 { 0x21, 0x90170150 }, /* use as headset mic, without its own jack detect */
7536 /* set 0x15 to HP-OUT ctrl */
7582 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
7592 { 0x18, 0x02a111f0 }, /* use as headset mic, without its own jack detect */
7602 { 0x18, 0x02a11030 }, /* use as headset mic */
7611 { 0x18, 0x01a11130 }, /* use as headset mic, without its own jack detect */
7626 { 0x19, 0x03a11020 }, /* headset mic with jack detect */
7633 { 0x19, 0x02a11120 }, /* use as headset mic, without its own jack detect */
7731 { 0x1b, 0x01a1913c }, /* use as headset mic, without its own jack detect */
7799 SND_PCI_QUIRK(0x1025, 0x072d, "Acer Aspire V5-571G", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
7800 SND_PCI_QUIRK(0x1025, 0x080d, "Acer Aspire V5-122P", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
7803 SND_PCI_QUIRK(0x1025, 0x0762, "Acer Aspire E1-472", ALC271_FIXUP_HP_GATE_MIC_JACK_E1_572),
7804 SND_PCI_QUIRK(0x1025, 0x0775, "Acer Aspire E1-572", ALC271_FIXUP_HP_GATE_MIC_JACK_E1_572),
7805 SND_PCI_QUIRK(0x1025, 0x079b, "Acer Aspire V5-573G", ALC282_FIXUP_ASPIRE_V5_PINS),
7806 SND_PCI_QUIRK(0x1025, 0x102b, "Acer Aspire C24-860", ALC286_FIXUP_ACER_AIO_MIC_NO_PRESENCE),
7807 SND_PCI_QUIRK(0x1025, 0x1065, "Acer Aspire C20-820", ALC269VC_FIXUP_ACER_HEADSET_MIC),
7809 SND_PCI_QUIRK(0x1025, 0x1099, "Acer Aspire E5-523G", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
7810 SND_PCI_QUIRK(0x1025, 0x110e, "Acer Aspire ES1-432", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
7817 SND_PCI_QUIRK(0x1025, 0x1308, "Acer Aspire Z24-890", ALC286_FIXUP_ACER_AIO_HEADSET_MIC),
7818 SND_PCI_QUIRK(0x1025, 0x132a, "Acer TravelMate B114-21", ALC233_FIXUP_ACER_HEADSET_MIC),
7819 SND_PCI_QUIRK(0x1025, 0x1330, "Acer TravelMate X514-51T", ALC255_FIXUP_ACER_HEADSET_MIC),
7820 SND_PCI_QUIRK(0x1025, 0x1430, "Acer TravelMate B311R-31", ALC256_FIXUP_ACER_MIC_NO_PRESENCE),
8004 SND_PCI_QUIRK(0x10f7, 0x8338, "Panasonic CF-SZ6", ALC269_FIXUP_HEADSET_MODE),
8006 …SND_PCI_QUIRK(0x144d, 0xc169, "Samsung Notebook 9 Pen (NP930SBE-K01US)", ALC298_FIXUP_SAMSUNG_HEAD…
8007 …SND_PCI_QUIRK(0x144d, 0xc176, "Samsung Notebook 9 Pro (NP930MBE-K04US)", ALC298_FIXUP_SAMSUNG_HEAD…
8008 …SND_PCI_QUIRK(0x144d, 0xc189, "Samsung Galaxy Flex Book (NT950QCG-X716)", ALC298_FIXUP_SAMSUNG_HEA…
8009 …SND_PCI_QUIRK(0x144d, 0xc18a, "Samsung Galaxy Book Ion (NP930XCJ-K01US)", ALC298_FIXUP_SAMSUNG_HEA…
8010 …SND_PCI_QUIRK(0x144d, 0xc830, "Samsung Galaxy Book Ion (NT950XCJ-X716A)", ALC298_FIXUP_SAMSUNG_HEA…
8012 …SND_PCI_QUIRK(0x144d, 0xc812, "Samsung Notebook Pen S (NT950SBE-X58)", ALC298_FIXUP_SAMSUNG_HEADPH…
8013 SND_PCI_QUIRK(0x1458, 0xfa53, "Gigabyte BXBT-2807", ALC283_FIXUP_HEADSET_MIC),
8014 SND_PCI_QUIRK(0x1462, 0xb120, "MSI Cubi MS-B120", ALC283_FIXUP_HEADSET_MIC),
8015 SND_PCI_QUIRK(0x1462, 0xb171, "Cubi N 8GL (MS-B171)", ALC283_FIXUP_HEADSET_MIC),
8052 SND_PCI_QUIRK(0x1558, 0x8a20, "Clevo NH55DCQ-Y", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
8053 SND_PCI_QUIRK(0x1558, 0x8a51, "Clevo NH70RCQ-Y", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
8054 SND_PCI_QUIRK(0x1558, 0x8d50, "Clevo NH55RCQ-M", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
8108 SND_PCI_QUIRK(0x17aa, 0x3902, "Lenovo E50-80", ALC269_FIXUP_DMIC_THINKPAD_ACPI),
8110 SND_PCI_QUIRK(0x17aa, 0x3978, "Lenovo B50-70", ALC269_FIXUP_DMIC_THINKPAD_ACPI),
8131 SND_PCI_QUIRK(0x19e5, 0x3204, "Huawei MACH-WX9", ALC256_FIXUP_HUAWEI_MACH_WX9_PINS),
8135 …b7d, 0xa831, "Ordissimo EVE2 ", ALC269VB_FIXUP_ORDISSIMO_EVE2), /* Also known as Malata PC-B1303 */
8204 {.id = ALC269_FIXUP_AMIC, .name = "laptop-amic"},
8205 {.id = ALC269_FIXUP_DMIC, .name = "laptop-dmic"},
8206 {.id = ALC269_FIXUP_STEREO_DMIC, .name = "alc269-dmic"},
8207 {.id = ALC271_FIXUP_DMIC, .name = "alc271-dmic"},
8208 {.id = ALC269_FIXUP_INV_DMIC, .name = "inv-dmic"},
8209 {.id = ALC269_FIXUP_HEADSET_MIC, .name = "headset-mic"},
8210 {.id = ALC269_FIXUP_HEADSET_MODE, .name = "headset-mode"},
8211 {.id = ALC269_FIXUP_HEADSET_MODE_NO_HP_MIC, .name = "headset-mode-no-hp-mic"},
8212 {.id = ALC269_FIXUP_LENOVO_DOCK, .name = "lenovo-dock"},
8213 {.id = ALC269_FIXUP_LENOVO_DOCK_LIMIT_BOOST, .name = "lenovo-dock-limit-boost"},
8214 {.id = ALC269_FIXUP_HP_GPIO_LED, .name = "hp-gpio-led"},
8215 {.id = ALC269_FIXUP_HP_DOCK_GPIO_MIC1_LED, .name = "hp-dock-gpio-mic1-led"},
8216 {.id = ALC269_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "dell-headset-multi"},
8217 {.id = ALC269_FIXUP_DELL2_MIC_NO_PRESENCE, .name = "dell-headset-dock"},
8218 {.id = ALC269_FIXUP_DELL3_MIC_NO_PRESENCE, .name = "dell-headset3"},
8219 {.id = ALC269_FIXUP_DELL4_MIC_NO_PRESENCE, .name = "dell-headset4"},
8220 {.id = ALC283_FIXUP_CHROME_BOOK, .name = "alc283-dac-wcaps"},
8221 {.id = ALC283_FIXUP_SENSE_COMBO_JACK, .name = "alc283-sense-combo"},
8222 {.id = ALC292_FIXUP_TPT440_DOCK, .name = "tpt440-dock"},
8225 {.id = ALC298_FIXUP_TPT470_DOCK_FIX, .name = "tpt470-dock-fix"},
8226 {.id = ALC298_FIXUP_TPT470_DOCK, .name = "tpt470-dock"},
8227 {.id = ALC233_FIXUP_LENOVO_MULTI_CODECS, .name = "dual-codecs"},
8228 {.id = ALC700_FIXUP_INTEL_REFERENCE, .name = "alc700-ref"},
8230 {.id = ALC269_FIXUP_DELL_M101Z, .name = "dell-m101z"},
8231 {.id = ALC269_FIXUP_ASUS_G73JW, .name = "asus-g73jw"},
8232 {.id = ALC269_FIXUP_LENOVO_EAPD, .name = "lenovo-eapd"},
8233 {.id = ALC275_FIXUP_SONY_HWEQ, .name = "sony-hweq"},
8236 {.id = ALC269_FIXUP_LIFEBOOK_EXTMIC, .name = "lifebook-extmic"},
8237 {.id = ALC269_FIXUP_LIFEBOOK_HP_PIN, .name = "lifebook-hp-pin"},
8238 {.id = ALC255_FIXUP_LIFEBOOK_U7x7_HEADSET_MIC, .name = "lifebook-u7x7"},
8239 {.id = ALC269VB_FIXUP_AMIC, .name = "alc269vb-amic"},
8240 {.id = ALC269VB_FIXUP_DMIC, .name = "alc269vb-dmic"},
8241 {.id = ALC269_FIXUP_HP_MUTE_LED_MIC1, .name = "hp-mute-led-mic1"},
8242 {.id = ALC269_FIXUP_HP_MUTE_LED_MIC2, .name = "hp-mute-led-mic2"},
8243 {.id = ALC269_FIXUP_HP_MUTE_LED_MIC3, .name = "hp-mute-led-mic3"},
8244 {.id = ALC269_FIXUP_HP_GPIO_MIC1_LED, .name = "hp-gpio-mic1"},
8245 {.id = ALC269_FIXUP_HP_LINE1_MIC1_LED, .name = "hp-line1-mic1"},
8247 {.id = ALC286_FIXUP_SONY_MIC_NO_PRESENCE, .name = "sony-nomic"},
8248 {.id = ALC269_FIXUP_ASPIRE_HEADSET_MIC, .name = "aspire-headset-mic"},
8249 {.id = ALC269_FIXUP_ASUS_X101, .name = "asus-x101"},
8250 {.id = ALC271_FIXUP_HP_GATE_MIC_JACK, .name = "acer-ao7xx"},
8251 {.id = ALC271_FIXUP_HP_GATE_MIC_JACK_E1_572, .name = "acer-aspire-e1"},
8252 {.id = ALC269_FIXUP_ACER_AC700, .name = "acer-ac700"},
8253 {.id = ALC269_FIXUP_LIMIT_INT_MIC_BOOST, .name = "limit-mic-boost"},
8254 {.id = ALC269VB_FIXUP_ASUS_ZENBOOK, .name = "asus-zenbook"},
8255 {.id = ALC269VB_FIXUP_ASUS_ZENBOOK_UX31A, .name = "asus-zenbook-ux31a"},
8257 {.id = ALC282_FIXUP_ASUS_TX300, .name = "asus-tx300"},
8258 {.id = ALC283_FIXUP_INT_MIC, .name = "alc283-int-mic"},
8259 {.id = ALC290_FIXUP_MONO_SPEAKERS_HSJACK, .name = "mono-speakers"},
8260 {.id = ALC290_FIXUP_SUBWOOFER_HSJACK, .name = "alc290-subwoofer"},
8262 {.id = ALC269_FIXUP_DMIC_THINKPAD_ACPI, .name = "dmic-thinkpad"},
8263 {.id = ALC255_FIXUP_ACER_MIC_NO_PRESENCE, .name = "alc255-acer"},
8264 {.id = ALC255_FIXUP_ASUS_MIC_NO_PRESENCE, .name = "alc255-asus"},
8265 {.id = ALC255_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc255-dell1"},
8266 {.id = ALC255_FIXUP_DELL2_MIC_NO_PRESENCE, .name = "alc255-dell2"},
8267 {.id = ALC293_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc293-dell1"},
8268 {.id = ALC283_FIXUP_HEADSET_MIC, .name = "alc283-headset"},
8269 {.id = ALC255_FIXUP_MIC_MUTE_LED, .name = "alc255-dell-mute"},
8270 {.id = ALC282_FIXUP_ASPIRE_V5_PINS, .name = "aspire-v5"},
8271 {.id = ALC280_FIXUP_HP_GPIO4, .name = "hp-gpio4"},
8272 {.id = ALC286_FIXUP_HP_GPIO_LED, .name = "hp-gpio-led"},
8273 {.id = ALC280_FIXUP_HP_GPIO2_MIC_HOTKEY, .name = "hp-gpio2-hotkey"},
8274 {.id = ALC280_FIXUP_HP_DOCK_PINS, .name = "hp-dock-pins"},
8275 {.id = ALC269_FIXUP_HP_DOCK_GPIO_MIC1_LED, .name = "hp-dock-gpio-mic"},
8276 {.id = ALC280_FIXUP_HP_9480M, .name = "hp-9480m"},
8277 {.id = ALC288_FIXUP_DELL_HEADSET_MODE, .name = "alc288-dell-headset"},
8278 {.id = ALC288_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc288-dell1"},
8279 {.id = ALC288_FIXUP_DELL_XPS_13, .name = "alc288-dell-xps13"},
8280 {.id = ALC292_FIXUP_DELL_E7X, .name = "dell-e7x"},
8281 {.id = ALC293_FIXUP_DISABLE_AAMIX_MULTIJACK, .name = "alc293-dell"},
8282 {.id = ALC298_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc298-dell1"},
8283 {.id = ALC298_FIXUP_DELL_AIO_MIC_NO_PRESENCE, .name = "alc298-dell-aio"},
8284 {.id = ALC275_FIXUP_DELL_XPS, .name = "alc275-dell-xps"},
8285 {.id = ALC293_FIXUP_LENOVO_SPK_NOISE, .name = "lenovo-spk-noise"},
8286 {.id = ALC233_FIXUP_LENOVO_LINE2_MIC_HOTKEY, .name = "lenovo-hotkey"},
8287 {.id = ALC255_FIXUP_DELL_SPK_NOISE, .name = "dell-spk-noise"},
8288 {.id = ALC225_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc225-dell1"},
8289 {.id = ALC295_FIXUP_DISABLE_DAC3, .name = "alc295-disable-dac3"},
8290 {.id = ALC285_FIXUP_SPEAKER2_TO_DAC1, .name = "alc285-speaker2-to-dac1"},
8291 {.id = ALC280_FIXUP_HP_HEADSET_MIC, .name = "alc280-hp-headset"},
8292 {.id = ALC221_FIXUP_HP_FRONT_MIC, .name = "alc221-hp-mic"},
8293 {.id = ALC298_FIXUP_SPK_VOLUME, .name = "alc298-spk-volume"},
8294 {.id = ALC256_FIXUP_DELL_INSPIRON_7559_SUBWOOFER, .name = "dell-inspiron-7559"},
8295 {.id = ALC269_FIXUP_ATIV_BOOK_8, .name = "ativ-book"},
8296 {.id = ALC221_FIXUP_HP_MIC_NO_PRESENCE, .name = "alc221-hp-mic"},
8297 {.id = ALC256_FIXUP_ASUS_HEADSET_MODE, .name = "alc256-asus-headset"},
8298 {.id = ALC256_FIXUP_ASUS_MIC, .name = "alc256-asus-mic"},
8299 {.id = ALC256_FIXUP_ASUS_AIO_GPIO2, .name = "alc256-asus-aio"},
8300 {.id = ALC233_FIXUP_ASUS_MIC_NO_PRESENCE, .name = "alc233-asus"},
8301 {.id = ALC233_FIXUP_EAPD_COEF_AND_MIC_NO_PRESENCE, .name = "alc233-eapd"},
8302 {.id = ALC294_FIXUP_LENOVO_MIC_LOCATION, .name = "alc294-lenovo-mic"},
8303 {.id = ALC225_FIXUP_DELL_WYSE_MIC_NO_PRESENCE, .name = "alc225-wyse"},
8304 {.id = ALC274_FIXUP_DELL_AIO_LINEOUT_VERB, .name = "alc274-dell-aio"},
8305 {.id = ALC255_FIXUP_DUMMY_LINEOUT_VERB, .name = "alc255-dummy-lineout"},
8306 {.id = ALC255_FIXUP_DELL_HEADSET_MIC, .name = "alc255-dell-headset"},
8307 {.id = ALC295_FIXUP_HP_X360, .name = "alc295-hp-x360"},
8308 {.id = ALC225_FIXUP_HEADSET_JACK, .name = "alc-headset-jack"},
8309 {.id = ALC295_FIXUP_CHROME_BOOK, .name = "alc-chrome-book"},
8310 {.id = ALC299_FIXUP_PREDATOR_SPK, .name = "predator-spk"},
8311 {.id = ALC298_FIXUP_HUAWEI_MBX_STEREO, .name = "huawei-mbx-stereo"},
8312 {.id = ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE, .name = "alc256-medion-headset"},
8313 {.id = ALC298_FIXUP_SAMSUNG_HEADPHONE_VERY_QUIET, .name = "alc298-samsung-headphone"},
8314 {.id = ALC255_FIXUP_XIAOMI_HEADSET_MIC, .name = "alc255-xiaomi-headset"},
8315 {.id = ALC274_FIXUP_HP_MIC, .name = "alc274-hp-mic-detect"},
8748 struct alc_spec *spec = codec->spec; in alc269_fill_coef()
8751 if (spec->codec_variant != ALC269_TYPE_ALC269VB) in alc269_fill_coef()
8771 if (val != -1 && (val & 0x0c00) >> 10 != 0x1) { in alc269_fill_coef()
8776 if (val != -1 && (val & 0x01c0) >> 6 != 0x4) { in alc269_fill_coef()
8797 spec = codec->spec; in patch_alc269()
8798 spec->gen.shared_mic_vref_pin = 0x18; in patch_alc269()
8799 codec->power_save_node = 0; in patch_alc269()
8802 codec->patch_ops.suspend = alc269_suspend; in patch_alc269()
8803 codec->patch_ops.resume = alc269_resume; in patch_alc269()
8805 spec->shutup = alc_default_shutup; in patch_alc269()
8806 spec->init_hook = alc_default_init; in patch_alc269()
8808 switch (codec->core.vendor_id) { in patch_alc269()
8810 spec->codec_variant = ALC269_TYPE_ALC269VA; in patch_alc269()
8813 if (codec->bus->pci && in patch_alc269()
8814 codec->bus->pci->subsystem_vendor == 0x1025 && in patch_alc269()
8815 spec->cdefine.platform_type == 1) in patch_alc269()
8817 spec->codec_variant = ALC269_TYPE_ALC269VB; in patch_alc269()
8820 if (codec->bus->pci && in patch_alc269()
8821 codec->bus->pci->subsystem_vendor == 0x17aa && in patch_alc269()
8822 codec->bus->pci->subsystem_device == 0x21f3) in patch_alc269()
8824 spec->codec_variant = ALC269_TYPE_ALC269VC; in patch_alc269()
8827 spec->codec_variant = ALC269_TYPE_ALC269VD; in patch_alc269()
8834 spec->shutup = alc269_shutup; in patch_alc269()
8835 spec->init_hook = alc269_fill_coef; in patch_alc269()
8841 spec->codec_variant = ALC269_TYPE_ALC280; in patch_alc269()
8844 spec->codec_variant = ALC269_TYPE_ALC282; in patch_alc269()
8845 spec->shutup = alc282_shutup; in patch_alc269()
8846 spec->init_hook = alc282_init; in patch_alc269()
8850 spec->codec_variant = ALC269_TYPE_ALC283; in patch_alc269()
8851 spec->shutup = alc283_shutup; in patch_alc269()
8852 spec->init_hook = alc283_init; in patch_alc269()
8856 spec->codec_variant = ALC269_TYPE_ALC284; in patch_alc269()
8859 spec->codec_variant = ALC269_TYPE_ALC293; in patch_alc269()
8863 spec->codec_variant = ALC269_TYPE_ALC286; in patch_alc269()
8866 spec->codec_variant = ALC269_TYPE_ALC298; in patch_alc269()
8870 spec->codec_variant = ALC269_TYPE_ALC255; in patch_alc269()
8871 spec->shutup = alc256_shutup; in patch_alc269()
8872 spec->init_hook = alc256_init; in patch_alc269()
8876 spec->codec_variant = ALC269_TYPE_ALC256; in patch_alc269()
8877 spec->shutup = alc256_shutup; in patch_alc269()
8878 spec->init_hook = alc256_init; in patch_alc269()
8879 spec->gen.mixer_nid = 0; /* ALC256 does not have any loopback mixer path */ in patch_alc269()
8882 spec->codec_variant = ALC269_TYPE_ALC257; in patch_alc269()
8883 spec->shutup = alc256_shutup; in patch_alc269()
8884 spec->init_hook = alc256_init; in patch_alc269()
8885 spec->gen.mixer_nid = 0; in patch_alc269()
8892 spec->codec_variant = ALC269_TYPE_ALC215; in patch_alc269()
8893 spec->shutup = alc225_shutup; in patch_alc269()
8894 spec->init_hook = alc225_init; in patch_alc269()
8895 spec->gen.mixer_nid = 0; in patch_alc269()
8900 spec->codec_variant = ALC269_TYPE_ALC225; in patch_alc269()
8901 spec->shutup = alc225_shutup; in patch_alc269()
8902 spec->init_hook = alc225_init; in patch_alc269()
8903 spec->gen.mixer_nid = 0; /* no loopback on ALC225, ALC295 and ALC299 */ in patch_alc269()
8908 spec->codec_variant = ALC269_TYPE_ALC294; in patch_alc269()
8909 spec->gen.mixer_nid = 0; /* ALC2x4 does not have any loopback mixer path */ in patch_alc269()
8911 spec->init_hook = alc294_init; in patch_alc269()
8914 spec->codec_variant = ALC269_TYPE_ALC300; in patch_alc269()
8915 spec->gen.mixer_nid = 0; /* no loopback on ALC300 */ in patch_alc269()
8918 spec->codec_variant = ALC269_TYPE_ALC623; in patch_alc269()
8924 spec->codec_variant = ALC269_TYPE_ALC700; in patch_alc269()
8925 spec->gen.mixer_nid = 0; /* ALC700 does not have any loopback mixer path */ in patch_alc269()
8927 spec->init_hook = alc294_init; in patch_alc269()
8933 spec->has_alc5505_dsp = 1; in patch_alc269()
8934 spec->init_hook = alc5505_dsp_init; in patch_alc269()
8950 spec->gen.beep_nid = 0x01; in patch_alc269()
8957 if (!spec->gen.no_analog && spec->gen.beep_nid && spec->gen.mixer_nid) { in patch_alc269()
8958 err = set_beep_amp(spec, spec->gen.mixer_nid, 0x04, HDA_INPUT); in patch_alc269()
8996 struct alc_spec *spec = codec->spec; in alc861_fixup_asus_amp_vref_0f()
9006 spec->gen.keep_vref_in_automute = 1; in alc861_fixup_asus_amp_vref_0f()
9009 /* suppress the jack-detection */
9014 codec->no_jack_detect = 1; in alc_fixup_no_jack_detect()
9075 spec = codec->spec; in patch_alc861()
9077 spec->gen.beep_nid = 0x23; in patch_alc861()
9080 spec->power_hook = alc_power_eapd; in patch_alc861()
9093 if (!spec->gen.no_analog) { in patch_alc861()
9109 * ALC861-VD support
9141 struct alc_spec *spec = codec->spec; in alc660vd_fixup_asus_gpio1()
9144 spec->gpio_mask |= 0x02; in alc660vd_fixup_asus_gpio1()
9161 SND_PCI_QUIRK(0x1043, 0x1339, "ASUS A7-K", ALC660VD_FIX_ASUS_GPIO1),
9162 SND_PCI_QUIRK(0x1179, 0xff31, "Toshiba L30-149", ALC861VD_FIX_DALLAS),
9177 spec = codec->spec; in patch_alc861vd()
9179 spec->gen.beep_nid = 0x23; in patch_alc861vd()
9181 spec->shutup = alc_eapd_shutup; in patch_alc861vd()
9193 if (!spec->gen.no_analog) { in patch_alc861vd()
9214 * 6-channel independent captures.
9216 * In addition, an independent DAC for the multi-playback (not used in this
9231 if (codec->core.vendor_id == 0x10ec0272 || codec->core.vendor_id == 0x10ec0663 || in alc662_parse_auto_config()
9232 codec->core.vendor_id == 0x10ec0665 || codec->core.vendor_id == 0x10ec0670 || in alc662_parse_auto_config()
9233 codec->core.vendor_id == 0x10ec0671) in alc662_parse_auto_config()
9267 struct alc_spec *spec = codec->spec; in alc_fixup_bass_chmap()
9268 spec->gen.pcm_rec[0]->stream[0].chmap = asus_pcm_2_1_chmaps; in alc_fixup_bass_chmap()
9277 struct alc_spec *spec = codec->spec; in gpio_led_power_filter()
9278 if (nid == codec->core.afg && power_state == AC_PWRST_D3 && spec->gpio_data) in gpio_led_power_filter()
9286 struct alc_spec *spec = codec->spec; in alc662_fixup_led_gpio1()
9290 spec->mute_led_polarity = 1; in alc662_fixup_led_gpio1()
9291 codec->power_filter = gpio_led_power_filter; in alc662_fixup_led_gpio1()
9298 struct alc_spec *spec = codec->spec; in alc662_usi_automute_hook()
9303 vref = spec->gen.hp_jack_present ? PIN_VREF80 : 0; in alc662_usi_automute_hook()
9312 struct alc_spec *spec = codec->spec; in alc662_fixup_usi_headset_mic()
9314 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc662_fixup_usi_headset_mic()
9315 spec->gen.hp_automute_hook = alc662_usi_automute_hook; in alc662_fixup_usi_headset_mic()
9325 * 0x15 - front left/front right in alc662_aspire_ethos_mute_speakers()
9326 * 0x18 - front center/ LFE in alc662_aspire_ethos_mute_speakers()
9363 struct alc_spec *spec = codec->spec; in alc671_fixup_hp_headset_mic2()
9366 { 0x19, 0x02a11040 }, /* use as headset mic, with its own jack detect */ in alc671_fixup_hp_headset_mic2()
9373 spec->gen.mixer_nid = 0; in alc671_fixup_hp_headset_mic2()
9374 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc671_fixup_hp_headset_mic2()
9495 {0x19, 0x90a7013f}, /* int-mic */
9531 { 0x19, 0x99a3092f }, /* int-mic */
9543 { 0x19, 0x99a3092f }, /* int-mic */
9556 { 0x19, 0x99a3094f }, /* int-mic */
9569 { 0x19, 0x99a3094f }, /* int-mic */
9583 { 0x19, 0x99a3094f }, /* int-mic */
9595 { 0x19, 0x99a3094f }, /* int-mic */
9608 { 0x19, 0x99a3094f }, /* int-mic */
9620 { 0x12, 0x99a30970 }, /* int-mic */
9666 { 0x19, 0x03a1113c }, /* use as headset mic, without its own jack detect */
9680 { 0x19, 0x03a1913d }, /* use as headphone mic, without its own jack detect */
9681 { 0x1b, 0x03a1113c }, /* use as headset mic, without its own jack detect */
9733 { 0x19, 0x03a1913d }, /* use as headphone mic, without its own jack detect */
9735 { 0x1b, 0x03a1113c }, /* use as headset mic, without its own jack detect */
9765 { 0x19, 0x03a1913d }, /* use as headphone mic, without its own jack detect */
9766 { 0x1b, 0x03a1113c }, /* use as headset mic, without its own jack detect */
9794 { 0x19, 0x02a1913c }, /* use as headset mic, without its own jack detect */
9827 { 0x1a, 0x02a1113c }, /* use as headset mic, without its own jack detect */
9836 { 0x1a, 0x01a11140 }, /* use as headset mic, without its own jack detect */
9854 SND_PCI_QUIRK(0x1025, 0x123c, "Acer Nitro N50-600", ALC662_FIXUP_ACER_NITRO_HEADSET_MODE),
9958 {.id = ALC662_FIXUP_HP_RP5800, .name = "hp-rp5800"},
9959 {.id = ALC662_FIXUP_ASUS_MODE1, .name = "asus-mode1"},
9960 {.id = ALC662_FIXUP_ASUS_MODE2, .name = "asus-mode2"},
9961 {.id = ALC662_FIXUP_ASUS_MODE3, .name = "asus-mode3"},
9962 {.id = ALC662_FIXUP_ASUS_MODE4, .name = "asus-mode4"},
9963 {.id = ALC662_FIXUP_ASUS_MODE5, .name = "asus-mode5"},
9964 {.id = ALC662_FIXUP_ASUS_MODE6, .name = "asus-mode6"},
9965 {.id = ALC662_FIXUP_ASUS_MODE7, .name = "asus-mode7"},
9966 {.id = ALC662_FIXUP_ASUS_MODE8, .name = "asus-mode8"},
9967 {.id = ALC662_FIXUP_ZOTAC_Z68, .name = "zotac-z68"},
9968 {.id = ALC662_FIXUP_INV_DMIC, .name = "inv-dmic"},
9969 {.id = ALC662_FIXUP_DELL_MIC_NO_PRESENCE, .name = "alc662-headset-multi"},
9970 {.id = ALC668_FIXUP_DELL_MIC_NO_PRESENCE, .name = "dell-headset-multi"},
9971 {.id = ALC662_FIXUP_HEADSET_MODE, .name = "alc662-headset"},
9972 {.id = ALC668_FIXUP_HEADSET_MODE, .name = "alc668-headset"},
9976 {.id = ALC668_FIXUP_DELL_XPS13, .name = "dell-xps13"},
9977 {.id = ALC662_FIXUP_ASUS_Nx50, .name = "asus-nx50"},
9978 {.id = ALC668_FIXUP_ASUS_Nx51, .name = "asus-nx51"},
9979 {.id = ALC668_FIXUP_ASUS_G751, .name = "asus-g751"},
9980 {.id = ALC891_FIXUP_HEADSET_MODE, .name = "alc891-headset"},
9981 {.id = ALC891_FIXUP_DELL_MIC_NO_PRESENCE, .name = "alc891-headset-multi"},
9982 {.id = ALC662_FIXUP_ACER_VERITON, .name = "acer-veriton"},
9983 {.id = ALC892_FIXUP_ASROCK_MOBO, .name = "asrock-mobo"},
9984 {.id = ALC662_FIXUP_USI_HEADSET_MODE, .name = "usi-headset"},
9985 {.id = ALC662_FIXUP_LENOVO_MULTI_CODECS, .name = "dual-codecs"},
9986 {.id = ALC669_FIXUP_ACER_ASPIRE_ETHOS, .name = "aspire-ethos"},
10060 spec = codec->spec; in patch_alc662()
10062 spec->shutup = alc_eapd_shutup; in patch_alc662()
10065 spec->parse_flags = HDA_PINCFG_NO_HP_FIXUP; in patch_alc662()
10069 switch (codec->core.vendor_id) { in patch_alc662()
10071 spec->init_hook = alc668_restore_default_value; in patch_alc662()
10085 spec->gen.beep_nid = 0x01; in patch_alc662()
10088 codec->bus->pci && codec->bus->pci->subsystem_vendor == 0x1025 && in patch_alc662()
10089 spec->cdefine.platform_type == 1) { in patch_alc662()
10100 if (!spec->gen.no_analog && spec->gen.beep_nid) { in patch_alc662()
10101 switch (codec->core.vendor_id) { in patch_alc662()
10143 /* ALC680 has no aa-loopback mixer */ in patch_alc680()
10204 HDA_CODEC_ENTRY(0x10ec0660, "ALC660-VD", patch_alc861vd),
10206 HDA_CODEC_ENTRY(0x10ec0862, "ALC861-VD", patch_alc861vd),
10244 MODULE_DESCRIPTION("Realtek HD-audio codec");