Lines Matching +full:headset +full:- +full:detect +full:- +full:gpios

1 // SPDX-License-Identifier: GPL-2.0-or-later
39 /* extra amp-initialization sequence types */
148 struct alc_spec *spec = codec->spec; in coef_mutex_lock()
151 mutex_lock(&spec->coef_mutex); in coef_mutex_lock()
156 struct alc_spec *spec = codec->spec; in coef_mutex_unlock()
158 mutex_unlock(&spec->coef_mutex); in coef_mutex_unlock()
210 if (val != -1) in __alc_update_coefex_idx()
230 struct alc_spec *spec = codec->spec; in alc_get_coef0()
232 if (!spec->coef0) in alc_get_coef0()
233 spec->coef0 = alc_read_coef_idx(codec, 0); in alc_get_coef0()
234 return spec->coef0; in alc_get_coef0()
247 #define WRITE_COEFEX(_nid, _idx, _val) UPDATE_COEFEX(_nid, _idx, -1, _val)
255 for (; fw->nid; fw++) { in alc_process_coef_fw()
256 if (fw->mask == (unsigned short)-1) in alc_process_coef_fw()
257 __alc_write_coefex_idx(codec, fw->nid, fw->idx, fw->val); in alc_process_coef_fw()
259 __alc_update_coefex_idx(codec, fw->nid, fw->idx, in alc_process_coef_fw()
260 fw->mask, fw->val); in alc_process_coef_fw()
272 struct alc_spec *spec = codec->spec; in alc_setup_gpio()
274 spec->gpio_mask |= mask; in alc_setup_gpio()
275 spec->gpio_dir |= mask; in alc_setup_gpio()
276 spec->gpio_data |= mask; in alc_setup_gpio()
281 struct alc_spec *spec = codec->spec; in alc_write_gpio_data()
284 spec->gpio_data); in alc_write_gpio_data()
290 struct alc_spec *spec = codec->spec; in alc_update_gpio_data()
291 unsigned int oldval = spec->gpio_data; in alc_update_gpio_data()
294 spec->gpio_data |= mask; in alc_update_gpio_data()
296 spec->gpio_data &= ~mask; in alc_update_gpio_data()
297 if (oldval != spec->gpio_data) in alc_update_gpio_data()
303 struct alc_spec *spec = codec->spec; in alc_write_gpio()
305 if (!spec->gpio_mask) in alc_write_gpio()
308 snd_hda_codec_write(codec, codec->core.afg, 0, in alc_write_gpio()
309 AC_VERB_SET_GPIO_MASK, spec->gpio_mask); in alc_write_gpio()
310 snd_hda_codec_write(codec, codec->core.afg, 0, in alc_write_gpio()
311 AC_VERB_SET_GPIO_DIRECTION, spec->gpio_dir); in alc_write_gpio()
312 if (spec->gpio_write_delay) in alc_write_gpio()
362 struct alc_spec *spec = codec->spec; in alc_fix_pll()
364 if (spec->pll_nid) in alc_fix_pll()
365 alc_update_coefex_idx(codec, spec->pll_nid, spec->pll_coef_idx, in alc_fix_pll()
366 1 << spec->pll_coef_bit, 0); in alc_fix_pll()
372 struct alc_spec *spec = codec->spec; in alc_fix_pll_init()
373 spec->pll_nid = nid; in alc_fix_pll_init()
374 spec->pll_coef_idx = coef_idx; in alc_fix_pll_init()
375 spec->pll_coef_bit = coef_bit; in alc_fix_pll_init()
379 /* update the master volume per volume-knob's unsol event */
393 val = snd_hda_codec_read(codec, jack->nid, 0, in alc_update_knob_master()
396 uctl->value.integer.value[0] = val; in alc_update_knob_master()
397 uctl->value.integer.value[1] = val; in alc_update_knob_master()
398 kctl->put(kctl, uctl); in alc_update_knob_master()
416 switch (codec->core.vendor_id) { in alc_fill_eapd_coef()
531 /* alc888-VA */ in alc888_coef_init()
533 /* alc888-VB */ in alc888_coef_init()
573 if (codec->bus->shutdown) in alc_headset_mic_no_shutup()
576 snd_array_for_each(&codec->init_pins, i, pin) { in alc_headset_mic_no_shutup()
578 if (pin->nid != mic_pin) in alc_headset_mic_no_shutup()
579 snd_hda_codec_read(codec, pin->nid, 0, in alc_headset_mic_no_shutup()
583 codec->pins_shutup = 1; in alc_headset_mic_no_shutup()
588 struct alc_spec *spec = codec->spec; in alc_shutup_pins()
590 if (spec->no_shutup_pins) in alc_shutup_pins()
593 switch (codec->core.vendor_id) { in alc_shutup_pins()
614 * just turning off EAPD and a little pause for avoiding pop-noise
618 struct alc_spec *spec = codec->spec; in alc_eapd_shutup()
621 if (!spec->no_depop_delay) in alc_eapd_shutup()
633 switch (codec->core.vendor_id) { in alc_auto_init_amp()
654 if (spec->gen.autocfg.hp_pins[0]) in alc_get_hp_pin()
655 return spec->gen.autocfg.hp_pins[0]; in alc_get_hp_pin()
656 if (spec->gen.autocfg.line_out_type == AC_JACK_HP_OUT) in alc_get_hp_pin()
657 return spec->gen.autocfg.line_out_pins[0]; in alc_get_hp_pin()
665 /* Could be any non-zero and even value. When used as fixup, tells
673 struct alc_spec *spec = codec->spec; in alc_fixup_sku_ignore()
675 spec->cdefine.fixup = 1; in alc_fixup_sku_ignore()
676 spec->cdefine.sku_cfg = ALC_FIXUP_SKU_IGNORE; in alc_fixup_sku_ignore()
683 struct alc_spec *spec = codec->spec; in alc_fixup_no_depop_delay()
686 spec->no_depop_delay = 1; in alc_fixup_no_depop_delay()
687 codec->depop_delay = 0; in alc_fixup_no_depop_delay()
695 struct alc_spec *spec = codec->spec; in alc_auto_parse_customize_define()
697 spec->cdefine.enable_pcbeep = 1; /* assume always enabled */ in alc_auto_parse_customize_define()
699 if (spec->cdefine.fixup) { in alc_auto_parse_customize_define()
700 ass = spec->cdefine.sku_cfg; in alc_auto_parse_customize_define()
702 return -1; in alc_auto_parse_customize_define()
706 if (!codec->bus->pci) in alc_auto_parse_customize_define()
707 return -1; in alc_auto_parse_customize_define()
708 ass = codec->core.subsystem_id & 0xffff; in alc_auto_parse_customize_define()
709 if (ass != codec->bus->pci->subsystem_device && (ass & 1)) in alc_auto_parse_customize_define()
713 if (codec->core.vendor_id == 0x10ec0260) in alc_auto_parse_customize_define()
719 codec->core.chip_name, ass); in alc_auto_parse_customize_define()
720 return -1; in alc_auto_parse_customize_define()
730 return -1; in alc_auto_parse_customize_define()
732 spec->cdefine.port_connectivity = ass >> 30; in alc_auto_parse_customize_define()
733 spec->cdefine.enable_pcbeep = (ass & 0x100000) >> 20; in alc_auto_parse_customize_define()
734 spec->cdefine.check_sum = (ass >> 16) & 0xf; in alc_auto_parse_customize_define()
735 spec->cdefine.customization = ass >> 8; in alc_auto_parse_customize_define()
737 spec->cdefine.sku_cfg = ass; in alc_auto_parse_customize_define()
738 spec->cdefine.external_amp = (ass & 0x38) >> 3; in alc_auto_parse_customize_define()
739 spec->cdefine.platform_type = (ass & 0x4) >> 2; in alc_auto_parse_customize_define()
740 spec->cdefine.swap = (ass & 0x2) >> 1; in alc_auto_parse_customize_define()
741 spec->cdefine.override = ass & 0x1; in alc_auto_parse_customize_define()
744 nid, spec->cdefine.sku_cfg); in alc_auto_parse_customize_define()
746 spec->cdefine.port_connectivity); in alc_auto_parse_customize_define()
747 codec_dbg(codec, "SKU: enable_pcbeep=0x%x\n", spec->cdefine.enable_pcbeep); in alc_auto_parse_customize_define()
748 codec_dbg(codec, "SKU: check_sum=0x%08x\n", spec->cdefine.check_sum); in alc_auto_parse_customize_define()
749 codec_dbg(codec, "SKU: customization=0x%08x\n", spec->cdefine.customization); in alc_auto_parse_customize_define()
750 codec_dbg(codec, "SKU: external_amp=0x%x\n", spec->cdefine.external_amp); in alc_auto_parse_customize_define()
751 codec_dbg(codec, "SKU: platform_type=0x%x\n", spec->cdefine.platform_type); in alc_auto_parse_customize_define()
752 codec_dbg(codec, "SKU: swap=0x%x\n", spec->cdefine.swap); in alc_auto_parse_customize_define()
753 codec_dbg(codec, "SKU: override=0x%x\n", spec->cdefine.override); in alc_auto_parse_customize_define()
758 /* return the position of NID in the list, or -1 if not found */
765 return -1; in find_idx_in_nid_list()
773 /* check subsystem ID and set up device-specific initialization;
776 /* 32-bit subsystem ID for BIOS loading in HD Audio codec.
780 * port-A --> pin 39/41, port-E --> pin 14/15, port-D --> pin 35/36
786 struct alc_spec *spec = codec->spec; in alc_subsystem_id()
788 if (spec->cdefine.fixup) { in alc_subsystem_id()
789 ass = spec->cdefine.sku_cfg; in alc_subsystem_id()
795 ass = codec->core.subsystem_id & 0xffff; in alc_subsystem_id()
796 if (codec->bus->pci && in alc_subsystem_id()
797 ass != codec->bus->pci->subsystem_device && (ass & 1)) in alc_subsystem_id()
810 if (codec->core.vendor_id == 0x10ec0260) in alc_subsystem_id()
831 ass & 0xffff, codec->core.vendor_id); in alc_subsystem_id()
835 * 2 : 0 --> Desktop, 1 --> Laptop in alc_subsystem_id()
840 if (spec->init_amp == ALC_INIT_UNDEFINED) { in alc_subsystem_id()
853 spec->init_amp = ALC_INIT_DEFAULT; in alc_subsystem_id()
865 * 12~11: Headphone out -> 00: PortA, 01: PortE, 02: PortD, 03: Resvered in alc_subsystem_id()
867 * 15 : 1 --> enable the function "Mute internal speaker in alc_subsystem_id()
874 if (found_in_nid_list(nid, spec->gen.autocfg.line_out_pins, in alc_subsystem_id()
875 spec->gen.autocfg.line_outs)) in alc_subsystem_id()
877 spec->gen.autocfg.hp_pins[0] = nid; in alc_subsystem_id()
882 /* Check the validity of ALC subsystem-id
883 * ports contains an array of 4 pin NIDs for port-A, E, D and I */
887 struct alc_spec *spec = codec->spec; in alc_ssid_check()
888 if (spec->init_amp == ALC_INIT_UNDEFINED) { in alc_ssid_check()
891 spec->init_amp = ALC_INIT_DEFAULT; in alc_ssid_check()
896 /* inverted digital-mic */
900 struct alc_spec *spec = codec->spec; in alc_fixup_inv_dmic()
902 spec->gen.inv_dmic_split = 1; in alc_fixup_inv_dmic()
929 ((codec)->core.dev.power.power_state.event == PM_EVENT_RESUME)
931 ((codec)->core.dev.power.power_state.event == PM_EVENT_RESTORE)
933 ((codec)->core.dev.power.power_state.event == PM_EVENT_FREEZE)
937 struct alc_spec *spec = codec->spec; in alc_init()
943 if (spec->init_hook) in alc_init()
944 spec->init_hook(codec); in alc_init()
946 spec->gen.skip_verbs = 1; /* applied in below */ in alc_init()
949 alc_auto_init_amp(codec, spec->init_amp); in alc_init()
962 struct alc_spec *spec = codec->spec; in alc_free()
965 hda_component_manager_free(&spec->comps, &comp_master_ops); in alc_free()
972 struct alc_spec *spec = codec->spec; in alc_shutup()
977 if (spec && spec->shutup) in alc_shutup()
978 spec->shutup(codec); in alc_shutup()
990 struct alc_spec *spec = codec->spec; in alc_suspend()
992 if (spec && spec->power_hook) in alc_suspend()
993 spec->power_hook(codec); in alc_suspend()
999 struct alc_spec *spec = codec->spec; in alc_resume()
1001 if (!spec->no_depop_delay) in alc_resume()
1003 codec->patch_ops.init(codec); in alc_resume()
1053 { 0x10ec0887, 0x00f0, 0x0030, "ALC887-VD" },
1054 { 0x10ec0888, 0x00f0, 0x0030, "ALC888-VD" },
1099 for (p = rename_tbl; p->vendor_id; p++) { in alc_codec_rename_from_preset()
1100 if (p->vendor_id != codec->core.vendor_id) in alc_codec_rename_from_preset()
1102 if ((alc_get_coef0(codec) & p->coef_mask) == p->coef_bits) in alc_codec_rename_from_preset()
1103 return alc_codec_rename(codec, p->name); in alc_codec_rename_from_preset()
1106 if (!codec->bus->pci) in alc_codec_rename_from_preset()
1108 for (q = rename_pci_tbl; q->codec_vendor_id; q++) { in alc_codec_rename_from_preset()
1109 if (q->codec_vendor_id != codec->core.vendor_id) in alc_codec_rename_from_preset()
1111 if (q->pci_subvendor != codec->bus->pci->subsystem_vendor) in alc_codec_rename_from_preset()
1113 if (!q->pci_subdevice || in alc_codec_rename_from_preset()
1114 q->pci_subdevice == codec->bus->pci->subsystem_device) in alc_codec_rename_from_preset()
1115 return alc_codec_rename(codec, q->name); in alc_codec_rename_from_preset()
1123 * Digital-beep handlers
1142 knew = snd_hda_gen_add_kctl(&spec->gen, NULL, in set_beep_amp()
1145 return -ENOMEM; in set_beep_amp()
1146 knew->private_value = beep_amp; in set_beep_amp()
1159 SND_PCI_QUIRK(0x1458, 0xa002, "GA-MA790X", 1),
1161 /* denylist -- no beep available */
1169 struct alc_spec *spec = codec->spec; in has_cdefine_beep()
1171 q = snd_pci_quirk_lookup(codec->bus->pci, beep_allow_list); in has_cdefine_beep()
1173 return q->value; in has_cdefine_beep()
1174 return spec->cdefine.enable_pcbeep; in has_cdefine_beep()
1189 struct alc_spec *spec = codec->spec; in alc_parse_auto_config()
1190 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in alc_parse_auto_config()
1194 spec->parse_flags); in alc_parse_auto_config()
1215 return -ENOMEM; in alc_alloc_spec()
1216 codec->spec = spec; in alc_alloc_spec()
1217 snd_hda_gen_spec_init(&spec->gen); in alc_alloc_spec()
1218 spec->gen.mixer_nid = mixer_nid; in alc_alloc_spec()
1219 spec->gen.own_eapd_ctl = 1; in alc_alloc_spec()
1220 codec->single_adc_amp = 1; in alc_alloc_spec()
1222 codec->spdif_status_reset = 1; in alc_alloc_spec()
1223 codec->forced_resume = 1; in alc_alloc_spec()
1224 codec->patch_ops = alc_patch_ops; in alc_alloc_spec()
1225 mutex_init(&spec->coef_mutex); in alc_alloc_spec()
1243 * ALC880 fix-ups
1273 /* enable the volume-knob widget support on NID 0x21 */
1314 { 0x1a, 0x0181344f }, /* line-in */
1362 { 0x19, 0x01a19950 }, /* mic-in */
1382 { 0x19, 0x01a19950 }, /* mic-in */
1422 { 0x18, 0x01a19950 }, /* mic-in */
1424 { 0x1a, 0x01813031 }, /* line-in */
1455 { 0x14, 0x01014010 }, /* line-out */
1459 { 0x18, 0x01a19c30 }, /* mic-in */
1461 { 0x1a, 0x01813031 }, /* line-in */
1462 { 0x1b, 0x02a19c40 }, /* front-mic */
1495 { 0x18, 0x01a19c30 }, /* mic-in */
1497 { 0x1a, 0x01813031 }, /* line-in */
1498 { 0x1b, 0x02a19c40 }, /* front-mic */
1531 { 0x18, 0x01a19c30 }, /* mic-in */
1532 { 0x19, 0x02a19c40 }, /* front-mic */
1533 { 0x1a, 0x01813031 }, /* line-in */
1563 { 0x1b, 0x0121401f }, /* HP with jack detect */
1597 * It's not quite sure whether BIOS sets the correct pin-config table
1622 SND_PCI_QUIRK(0x1695, 0x4012, "EPox EP-5LDA", ALC880_FIXUP_5ST_DIG),
1637 SND_PCI_QUIRK(0xa0a0, 0x0560, "AOpen i915GMm-HFS", ALC880_FIXUP_5ST_DIG),
1644 {.id = ALC880_FIXUP_3ST_DIG, .name = "3stack-digout"},
1646 {.id = ALC880_FIXUP_5ST_DIG, .name = "5stack-digout"},
1648 {.id = ALC880_FIXUP_6ST_DIG, .name = "6stack-digout"},
1649 {.id = ALC880_FIXUP_6ST_AUTOMUTE, .name = "6stack-automute"},
1666 spec = codec->spec; in patch_alc880()
1667 spec->gen.need_dac_fix = 1; in patch_alc880()
1668 spec->gen.beep_nid = 0x01; in patch_alc880()
1670 codec->patch_ops.unsol_event = alc880_unsol_event; in patch_alc880()
1683 if (!spec->gen.no_analog) { in patch_alc880()
1728 struct alc_spec *spec = codec->spec; in alc260_gpio1_automute()
1730 alc_update_gpio_data(codec, 0x01, spec->gen.hp_jack_present); in alc260_gpio1_automute()
1736 struct alc_spec *spec = codec->spec; in alc260_fixup_gpio1_toggle()
1741 spec->gen.automute_hook = alc260_gpio1_automute; in alc260_fixup_gpio1_toggle()
1742 spec->gen.detect_hp = 1; in alc260_fixup_gpio1_toggle()
1743 spec->gen.automute_speaker = 1; in alc260_fixup_gpio1_toggle()
1744 spec->gen.autocfg.hp_pins[0] = 0x0f; /* copy it for automute */ in alc260_fixup_gpio1_toggle()
1754 struct alc_spec *spec = codec->spec; in alc260_fixup_kn1()
1774 spec->init_amp = ALC_INIT_NONE; in alc260_fixup_kn1()
1782 struct alc_spec *spec = codec->spec; in alc260_fixup_fsc_s7020()
1784 spec->init_amp = ALC_INIT_NONE; in alc260_fixup_fsc_s7020()
1790 struct alc_spec *spec = codec->spec; in alc260_fixup_fsc_s7020_jwse()
1792 spec->gen.add_jack_modes = 1; in alc260_fixup_fsc_s7020_jwse()
1793 spec->gen.hp_mic = 1; in alc260_fixup_fsc_s7020_jwse()
1900 {.id = ALC260_FIXUP_FSC_S7020_JWSE, .name = "fujitsu-jwse"},
1915 spec = codec->spec; in patch_alc260()
1920 spec->gen.prefer_hp_amp = 1; in patch_alc260()
1921 spec->gen.beep_nid = 0x01; in patch_alc260()
1923 spec->shutup = alc_eapd_shutup; in patch_alc260()
1936 if (!spec->gen.no_analog) { in patch_alc260()
1958 * 6-channel independent captures.
1960 * In addition, an independent DAC for the multi-playback (not used in this
2024 struct alc_spec *spec = codec->spec; in alc885_fixup_macpro_gpio()
2026 spec->gpio_write_delay = true; in alc885_fixup_macpro_gpio()
2060 struct alc_spec *spec = codec->spec; in alc889_fixup_mbp_vref()
2072 spec->gen.keep_vref_in_automute = 1; in alc889_fixup_mbp_vref()
2080 struct alc_spec *spec = codec->spec; in alc889_fixup_mac_pins()
2089 spec->gen.keep_vref_in_automute = 1; in alc889_fixup_mac_pins()
2124 * all-in-one desktop PCs (for example VGC-LN51JGB) through DAC 0x05
2129 struct alc_spec *spec = codec->spec; in alc882_fixup_no_primary_hp()
2131 spec->gen.no_primary_hp = 1; in alc882_fixup_no_primary_hp()
2132 spec->gen.no_multi_io = 1; in alc882_fixup_no_primary_hp()
2139 /* For dual-codec configuration, we need to disable some features to avoid
2145 struct alc_spec *spec = codec->spec; in alc_fixup_dual_codecs()
2150 spec->gen.suppress_vmaster = 1; in alc_fixup_dual_codecs()
2151 /* auto-mute and auto-mic switch don't work with multiple codecs */ in alc_fixup_dual_codecs()
2152 spec->gen.suppress_auto_mute = 1; in alc_fixup_dual_codecs()
2153 spec->gen.suppress_auto_mic = 1; in alc_fixup_dual_codecs()
2155 spec->gen.mixer_nid = 0; in alc_fixup_dual_codecs()
2157 codec->force_pin_prefix = 1; in alc_fixup_dual_codecs()
2167 snd_ctl_rename(codec->card, kctl, newname); in rename_ctl()
2178 strcpy(codec->card->longname, "HDAudio-Gigabyte-ALC1220DualCodecs"); in alc1220_fixup_gb_dual_codecs()
2183 codec->addr == 0 ? in alc1220_fixup_gb_dual_codecs()
2184 "Rear-Panel Capture Volume" : in alc1220_fixup_gb_dual_codecs()
2185 "Front-Panel Capture Volume"); in alc1220_fixup_gb_dual_codecs()
2187 codec->addr == 0 ? in alc1220_fixup_gb_dual_codecs()
2188 "Rear-Panel Capture Switch" : in alc1220_fixup_gb_dual_codecs()
2189 "Front-Panel Capture Switch"); in alc1220_fixup_gb_dual_codecs()
2249 struct alc_spec *spec = codec->spec; in alc887_asus_hp_automute_hook()
2254 if (spec->gen.hp_jack_present) in alc887_asus_hp_automute_hook()
2264 struct alc_spec *spec = codec->spec; in alc887_fixup_asus_jack()
2268 spec->gen.hp_automute_hook = alc887_asus_hp_automute_hook; in alc887_fixup_asus_jack()
2317 { 0x1b, 0x02214120 }, /* Front HP jack is flaky, disable jack detect */
2422 /* setting bits 1-5 disables DAC nids 0x02-0x06
2535 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
2544 { 0x15, 0x02a14150 }, /* use as headset mic, without its own jack detect */
2566 { 0x18, PIN_VREF100 }, /* headset mic */
2590 SND_PCI_QUIRK(0x1025, 0x0155, "Packard-Bell M5120", ALC882_FIXUP_PB_M5210),
2607 SND_PCI_QUIRK(0x1043, 0x8797, "ASUS TUF B550M-PLUS", ALCS1200A_FIXUP_MIC_VREF),
2608 SND_PCI_QUIRK(0x104d, 0x9043, "Sony Vaio VGC-LN51JGB", ALC882_FIXUP_NO_PRIMARY_HP),
2640 SND_PCI_QUIRK(0x13fe, 0x1009, "Advantech MIT-W101", ALC886_FIXUP_EAPD),
2641 SND_PCI_QUIRK(0x1458, 0xa002, "Gigabyte EP45-DS3/Z87X-UD3H", ALC889_FIXUP_FRONT_HP_NO_PRESENCE),
2642 SND_PCI_QUIRK(0x1458, 0xa0b8, "Gigabyte AZ370-Gaming", ALC1220_FIXUP_GB_DUAL_CODECS),
2646 SND_PCI_QUIRK(0x1462, 0x11f7, "MSI-GE63", ALC1220_FIXUP_CLEVO_P950),
2647 SND_PCI_QUIRK(0x1462, 0x1228, "MSI-GP63", ALC1220_FIXUP_CLEVO_P950),
2648 SND_PCI_QUIRK(0x1462, 0x1229, "MSI-GP73", ALC1220_FIXUP_CLEVO_P950),
2649 SND_PCI_QUIRK(0x1462, 0x1275, "MSI-GL63", ALC1220_FIXUP_CLEVO_P950),
2650 SND_PCI_QUIRK(0x1462, 0x1276, "MSI-GL73", ALC1220_FIXUP_CLEVO_P950),
2651 SND_PCI_QUIRK(0x1462, 0x1293, "MSI-GP65", ALC1220_FIXUP_CLEVO_P950),
2652 SND_PCI_QUIRK(0x1462, 0x7350, "MSI-7350", ALC889_FIXUP_CD),
2654 SND_PCI_QUIRK(0x1462, 0xda57, "MSI Z270-Gaming", ALC1220_FIXUP_GB_DUAL_CODECS),
2656 SND_PCI_QUIRK(0x147b, 0x107a, "Abit AW9D-MAX", ALC882_FIXUP_ABIT_AW9D_MAX),
2663 SND_PCI_QUIRK(0x1558, 0x65e5, "Clevo PC50D[PRS](?:-D|-G)?", ALC1220_FIXUP_CLEVO_PB51ED_PINS),
2667 SND_PCI_QUIRK(0x1558, 0x66a6, "Clevo PE60SN[CDE]-[GS]", ALC1220_FIXUP_CLEVO_PB51ED_PINS),
2670 SND_PCI_QUIRK(0x1558, 0x67e5, "Clevo PC70D[PRS](?:-D|-G)?", ALC1220_FIXUP_CLEVO_PB51ED_PINS),
2675 SND_PCI_QUIRK(0x1558, 0x7715, "Clevo X170KM-G", ALC1220_FIXUP_CLEVO_PB51ED),
2685 SND_PCI_QUIRK(0x1558, 0x96e1, "Clevo P960[ER][CDFN]-K", ALC1220_FIXUP_CLEVO_P950),
2687 SND_PCI_QUIRK(0x1558, 0x97e2, "Clevo P970RC-M", ALC1220_FIXUP_CLEVO_P950),
2697 {.id = ALC882_FIXUP_ABIT_AW9D_MAX, .name = "abit-aw9d"},
2698 {.id = ALC882_FIXUP_LENOVO_Y530, .name = "lenovo-y530"},
2699 {.id = ALC882_FIXUP_ACER_ASPIRE_7736, .name = "acer-aspire-7736"},
2700 {.id = ALC882_FIXUP_ASUS_W90V, .name = "asus-w90v"},
2702 {.id = ALC889_FIXUP_FRONT_HP_NO_PRESENCE, .name = "no-front-hp"},
2703 {.id = ALC889_FIXUP_VAIO_TT, .name = "vaio-tt"},
2705 {.id = ALC882_FIXUP_EAPD, .name = "alc882-eapd"},
2706 {.id = ALC883_FIXUP_EAPD, .name = "alc883-eapd"},
2710 {.id = ALC889_FIXUP_COEF, .name = "alc889-coef"},
2711 {.id = ALC882_FIXUP_ASUS_W2JC, .name = "asus-w2jc"},
2712 {.id = ALC882_FIXUP_ACER_ASPIRE_4930G, .name = "acer-aspire-4930g"},
2713 {.id = ALC882_FIXUP_ACER_ASPIRE_8930G, .name = "acer-aspire-8930g"},
2714 {.id = ALC883_FIXUP_ACER_EAPD, .name = "acer-aspire"},
2715 {.id = ALC885_FIXUP_MACPRO_GPIO, .name = "macpro-gpio"},
2716 {.id = ALC889_FIXUP_DAC_ROUTE, .name = "dac-route"},
2717 {.id = ALC889_FIXUP_MBP_VREF, .name = "mbp-vref"},
2718 {.id = ALC889_FIXUP_IMAC91_VREF, .name = "imac91-vref"},
2719 {.id = ALC889_FIXUP_MBA11_VREF, .name = "mba11-vref"},
2720 {.id = ALC889_FIXUP_MBA21_VREF, .name = "mba21-vref"},
2721 {.id = ALC889_FIXUP_MP11_VREF, .name = "mp11-vref"},
2722 {.id = ALC889_FIXUP_MP41_VREF, .name = "mp41-vref"},
2723 {.id = ALC882_FIXUP_INV_DMIC, .name = "inv-dmic"},
2724 {.id = ALC882_FIXUP_NO_PRIMARY_HP, .name = "no-primary-hp"},
2725 {.id = ALC887_FIXUP_ASUS_BASS, .name = "asus-bass"},
2726 {.id = ALC1220_FIXUP_GB_DUAL_CODECS, .name = "dual-codecs"},
2727 {.id = ALC1220_FIXUP_GB_X570, .name = "gb-x570"},
2728 {.id = ALC1220_FIXUP_CLEVO_P950, .name = "clevo-p950"},
2742 SND_HDA_PIN_QUIRK(0x10ec1220, 0x1462, "MS-7C35", ALC1220_FIXUP_CLEVO_P950,
2776 spec = codec->spec; in patch_alc882()
2778 switch (codec->core.vendor_id) { in patch_alc882()
2801 spec->gen.beep_nid = 0x01; in patch_alc882()
2808 if (!spec->gen.no_analog && spec->gen.beep_nid) { in patch_alc882()
2926 SND_PCI_QUIRK(0x17ff, 0x058d, "Benq T31-16", ALC262_FIXUP_BENQ_T31),
2932 {.id = ALC262_FIXUP_INV_DMIC, .name = "inv-dmic"},
2933 {.id = ALC262_FIXUP_FSC_H270, .name = "fsc-h270"},
2934 {.id = ALC262_FIXUP_FSC_S7110, .name = "fsc-s7110"},
2935 {.id = ALC262_FIXUP_HP_Z200, .name = "hp-z200"},
2937 {.id = ALC262_FIXUP_LENOVO_3000, .name = "lenovo-3000"},
2939 {.id = ALC262_FIXUP_BENQ_T31, .name = "benq-t31"},
2955 spec = codec->spec; in patch_alc262()
2956 spec->gen.shared_mic_vref_pin = 0x18; in patch_alc262()
2958 spec->shutup = alc_eapd_shutup; in patch_alc262()
2962 * under-run in patch_alc262()
2977 spec->gen.beep_nid = 0x01; in patch_alc262()
2984 if (!spec->gen.no_analog && spec->gen.beep_nid) { in patch_alc262()
3010 mutex_lock(&codec->control_mutex); in alc268_beep_switch_put()
3011 pval = kcontrol->private_value; in alc268_beep_switch_put()
3012 kcontrol->private_value = (pval & ~0xff) | 0x0f; in alc268_beep_switch_put()
3015 kcontrol->private_value = (pval & ~0xff) | 0x10; in alc268_beep_switch_put()
3018 kcontrol->private_value = pval; in alc268_beep_switch_put()
3019 mutex_unlock(&codec->control_mutex); in alc268_beep_switch_put()
3072 {.id = ALC268_FIXUP_INV_DMIC, .name = "inv-dmic"},
3073 {.id = ALC268_FIXUP_HP_EAPD, .name = "hp-eapd"},
3104 /* ALC268 has no aa-loopback mixer */ in patch_alc268()
3109 spec = codec->spec; in patch_alc268()
3111 spec->gen.beep_nid = 0x01; in patch_alc268()
3113 spec->shutup = alc_eapd_shutup; in patch_alc268()
3125 if (err > 0 && !spec->gen.no_analog && in patch_alc268()
3126 spec->gen.autocfg.speaker_pins[0] != 0x1d) { in patch_alc268()
3128 if (!snd_hda_gen_add_kctl(&spec->gen, NULL, in patch_alc268()
3130 err = -ENOMEM; in patch_alc268()
3165 /* different alc269-variants */
3199 struct alc_spec *spec = codec->spec; in alc269_parse_auto_config()
3202 switch (spec->codec_variant) { in alc269_parse_auto_config()
3250 if (jack->unsol_res & (7 << 13)) in alc_headset_btn_callback()
3253 if (jack->unsol_res & (1 << 16 | 3 << 8)) in alc_headset_btn_callback()
3257 if (jack->unsol_res & (7 << 23)) in alc_headset_btn_callback()
3261 if (jack->unsol_res & (7 << 10)) in alc_headset_btn_callback()
3264 snd_hda_jack_set_button_state(codec, jack->nid, report); in alc_headset_btn_callback()
3269 struct alc_spec *spec = codec->spec; in alc_disable_headset_jack_key()
3271 if (!spec->has_hs_key) in alc_disable_headset_jack_key()
3274 switch (codec->core.vendor_id) { in alc_disable_headset_jack_key()
3299 struct alc_spec *spec = codec->spec; in alc_enable_headset_jack_key()
3301 if (!spec->has_hs_key) in alc_enable_headset_jack_key()
3304 switch (codec->core.vendor_id) { in alc_enable_headset_jack_key()
3330 struct alc_spec *spec = codec->spec; in alc_fixup_headset_jack()
3335 spec->has_hs_key = 1; in alc_fixup_headset_jack()
3344 snd_hda_jack_add_kctl(codec, 0x55, "Headset Jack", in alc_fixup_headset_jack()
3360 struct alc_spec *spec = codec->spec; in alc269_shutup()
3362 if (spec->codec_variant == ALC269_TYPE_ALC269VB) in alc269_shutup()
3364 if (spec->codec_variant == ALC269_TYPE_ALC269VB && in alc269_shutup()
3411 struct alc_spec *spec = codec->spec; in alc282_init()
3448 struct alc_spec *spec = codec->spec; in alc282_shutup()
3471 if (!spec->no_shutup_pins) in alc282_shutup()
3527 struct alc_spec *spec = codec->spec; in alc283_init()
3555 /* 3k pull low control for Headset jack. */ in alc283_init()
3563 struct alc_spec *spec = codec->spec; in alc283_shutup()
3585 if (!spec->no_shutup_pins) in alc283_shutup()
3600 struct alc_spec *spec = codec->spec; in alc256_init()
3604 if (spec->ultra_low_power) { in alc256_init()
3641 * Documentation/sound/hd-audio/realtek-pc-beep.rst for details of in alc256_init()
3649 struct alc_spec *spec = codec->spec; in alc256_shutup()
3667 /* 3k pull low control for Headset jack. */ in alc256_shutup()
3670 * when booting with headset plugged. So skip setting it for the codec alc257 in alc256_shutup()
3672 if (spec->en_3kpull_low) in alc256_shutup()
3675 if (!spec->no_shutup_pins) in alc256_shutup()
3684 if (spec->ultra_low_power) { in alc256_shutup()
3697 struct alc_spec *spec = codec->spec; in alc285_hp_init()
3747 struct alc_spec *spec = codec->spec; in alc225_init()
3751 if (spec->ultra_low_power) { in alc225_init()
3758 if (spec->codec_variant != ALC269_TYPE_ALC287 && in alc225_init()
3759 spec->codec_variant != ALC269_TYPE_ALC245) in alc225_init()
3761 if (!spec->done_hp_init || in alc225_init()
3765 spec->done_hp_init = true; in alc225_init()
3802 struct alc_spec *spec = codec->spec; in alc225_shutup()
3814 /* 3k pull low control for Headset jack. */ in alc225_shutup()
3840 if (spec->ultra_low_power) { in alc225_shutup()
3852 struct alc_spec *spec = codec->spec; in alc222_init()
3888 struct alc_spec *spec = codec->spec; in alc222_shutup()
3925 struct alc_spec *spec = codec->spec; in alc_default_init()
3952 struct alc_spec *spec = codec->spec; in alc_default_shutup()
3971 if (!spec->no_shutup_pins) in alc_default_shutup()
3983 struct alc_spec *spec = codec->spec; in alc294_hp_init()
3995 if (!spec->no_shutup_pins) in alc294_hp_init()
4015 struct alc_spec *spec = codec->spec; in alc294_init()
4018 if (!spec->done_hp_init || in alc294_init()
4019 codec->core.dev.power.power_state.event == PM_EVENT_RESTORE) { in alc294_init()
4021 spec->done_hp_init = true; in alc294_init()
4120 struct alc_spec *spec = codec->spec; in alc269_suspend()
4122 if (spec->has_alc5505_dsp) in alc269_suspend()
4130 struct alc_spec *spec = codec->spec; in alc269_resume()
4132 if (spec->codec_variant == ALC269_TYPE_ALC269VB) in alc269_resume()
4134 if (spec->codec_variant == ALC269_TYPE_ALC269VB && in alc269_resume()
4139 codec->patch_ops.init(codec); in alc269_resume()
4141 if (spec->codec_variant == ALC269_TYPE_ALC269VB) in alc269_resume()
4143 if (spec->codec_variant == ALC269_TYPE_ALC269VB && in alc269_resume()
4155 if (spec->gpio_data) in alc269_resume()
4158 if (spec->has_alc5505_dsp) in alc269_resume()
4167 struct alc_spec *spec = codec->spec; in alc269_fixup_pincfg_no_hp_to_lineout()
4170 spec->parse_flags = HDA_PINCFG_NO_HP_FIXUP; in alc269_fixup_pincfg_no_hp_to_lineout()
4196 struct alc_spec *spec = codec->spec; in alc269_fixup_headset_mic()
4199 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc269_fixup_headset_mic()
4212 if (strcmp(codec->core.chip_name, "ALC271X") && in alc271_fixup_dmic()
4213 strcmp(codec->core.chip_name, "ALC269VB")) in alc271_fixup_dmic()
4232 struct alc_spec *spec = codec->spec; in alc269_fixup_pcm_44k()
4240 spec->gen.stream_analog_playback = &alc269_44k_pcm_analog_playback; in alc269_fixup_pcm_44k()
4241 spec->gen.stream_analog_capture = &alc269_44k_pcm_analog_capture; in alc269_fixup_pcm_44k()
4247 /* The digital-mic unit sends PDM (differential signal) instead of in alc269_fixup_stereo_dmic()
4267 struct alc_spec *spec = codec->spec; in alc269_fixup_quanta_mute()
4270 spec->gen.automute_hook = alc269_quanta_automute; in alc269_fixup_quanta_mute()
4276 struct alc_spec *spec = codec->spec; in alc269_x101_hp_automute_hook()
4281 vref = spec->gen.hp_jack_present ? PIN_VREF80 : 0; in alc269_x101_hp_automute_hook()
4310 alc_write_coef_idx(codec, 0x23, initval->value_0x23); in alc298_huawei_mbx_stereo_seq()
4312 if (initval->value_0x23 != 0x1e) in alc298_huawei_mbx_stereo_seq()
4313 alc_write_coef_idx(codec, 0x25, initval->value_0x25); in alc298_huawei_mbx_stereo_seq()
4352 for (seq = dac_init; seq->value_0x23; seq++) in alc298_fixup_huawei_mbx_stereo()
4359 struct alc_spec *spec = codec->spec; in alc269_fixup_x101_headset_mic()
4361 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc269_fixup_x101_headset_mic()
4362 spec->gen.hp_automute_hook = alc269_x101_hp_automute_hook; in alc269_fixup_x101_headset_mic()
4384 /* update mute-LED according to the speaker mute state via mic VREF pin */
4388 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in vref_mute_led_set()
4389 struct alc_spec *spec = codec->spec; in vref_mute_led_set()
4391 alc_update_vref_led(codec, spec->mute_led_nid, in vref_mute_led_set()
4392 spec->mute_led_polarity, brightness); in vref_mute_led_set()
4401 struct alc_spec *spec = codec->spec; in led_power_filter()
4404 (nid != spec->mute_led_nid && nid != spec->cap_mute_led_nid)) in led_power_filter()
4417 struct alc_spec *spec = codec->spec; in alc269_fixup_hp_mute_led()
4425 if (sscanf(dev->name, "HP_Mute_LED_%d_%x", &pol, &pin) != 2) in alc269_fixup_hp_mute_led()
4429 spec->mute_led_polarity = pol; in alc269_fixup_hp_mute_led()
4430 spec->mute_led_nid = pin - 0x0a + 0x18; in alc269_fixup_hp_mute_led()
4432 codec->power_filter = led_power_filter; in alc269_fixup_hp_mute_led()
4434 "Detected mute LED for %x:%d\n", spec->mute_led_nid, in alc269_fixup_hp_mute_led()
4435 spec->mute_led_polarity); in alc269_fixup_hp_mute_led()
4444 struct alc_spec *spec = codec->spec; in alc269_fixup_hp_mute_led_micx()
4447 spec->mute_led_polarity = 0; in alc269_fixup_hp_mute_led_micx()
4448 spec->mute_led_nid = pin; in alc269_fixup_hp_mute_led_micx()
4450 codec->power_filter = led_power_filter; in alc269_fixup_hp_mute_led_micx()
4478 alc_update_gpio_data(codec, mask, !enabled); /* muted -> LED on */ in alc_update_gpio_led()
4485 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in gpio_mute_led_set()
4486 struct alc_spec *spec = codec->spec; in gpio_mute_led_set()
4488 alc_update_gpio_led(codec, spec->gpio_mute_led_mask, in gpio_mute_led_set()
4489 spec->mute_led_polarity, !brightness); in gpio_mute_led_set()
4493 /* turn on/off mic-mute LED via GPIO per capture hook */
4497 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in micmute_led_set()
4498 struct alc_spec *spec = codec->spec; in micmute_led_set()
4500 alc_update_gpio_led(codec, spec->gpio_mic_led_mask, in micmute_led_set()
4501 spec->micmute_led_polarity, !brightness); in micmute_led_set()
4505 /* setup mute and mic-mute GPIO bits, add hooks appropriately */
4511 struct alc_spec *spec = codec->spec; in alc_fixup_hp_gpio_led()
4518 spec->gpio_mute_led_mask = mute_mask; in alc_fixup_hp_gpio_led()
4522 spec->gpio_mic_led_mask = micmute_mask; in alc_fixup_hp_gpio_led()
4560 struct alc_spec *spec = codec->spec; in alc245_fixup_hp_gpio_led()
4563 spec->micmute_led_polarity = 1; in alc245_fixup_hp_gpio_led()
4567 /* turn on/off mic-mute LED per capture hook via VREF change */
4571 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in vref_micmute_led_set()
4572 struct alc_spec *spec = codec->spec; in vref_micmute_led_set()
4574 alc_update_vref_led(codec, spec->cap_mute_led_nid, in vref_micmute_led_set()
4575 spec->micmute_led_polarity, brightness); in vref_micmute_led_set()
4582 struct alc_spec *spec = codec->spec; in alc269_fixup_hp_gpio_mic1_led()
4589 spec->gpio_mask |= 0x10; in alc269_fixup_hp_gpio_mic1_led()
4590 spec->gpio_dir |= 0x10; in alc269_fixup_hp_gpio_mic1_led()
4591 spec->cap_mute_led_nid = 0x18; in alc269_fixup_hp_gpio_mic1_led()
4593 codec->power_filter = led_power_filter; in alc269_fixup_hp_gpio_mic1_led()
4600 struct alc_spec *spec = codec->spec; in alc280_fixup_hp_gpio4()
4604 spec->cap_mute_led_nid = 0x18; in alc280_fixup_hp_gpio4()
4606 codec->power_filter = led_power_filter; in alc280_fixup_hp_gpio4()
4616 struct alc_spec *spec = codec->spec; in alc245_fixup_hp_x360_amp()
4620 spec->gpio_mask |= 0x01; in alc245_fixup_hp_x360_amp()
4621 spec->gpio_dir |= 0x01; in alc245_fixup_hp_x360_amp()
4652 struct alc_spec *spec = codec->spec; in alc274_fixup_hp_envy_gpio()
4655 spec->gpio_mask |= 0x04; in alc274_fixup_hp_envy_gpio()
4656 spec->gpio_dir |= 0x04; in alc274_fixup_hp_envy_gpio()
4657 spec->gen.pcm_playback_hook = alc274_hp_envy_pcm_hook; in alc274_fixup_hp_envy_gpio()
4668 alc_update_coef_idx(codec, led->idx, led->mask, in alc_update_coef_led()
4669 on ? led->on : led->off); in alc_update_coef_led()
4672 /* update mute-LED according to the speaker mute state via COEF bit */
4676 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in coef_mute_led_set()
4677 struct alc_spec *spec = codec->spec; in coef_mute_led_set()
4679 alc_update_coef_led(codec, &spec->mute_led_coef, in coef_mute_led_set()
4680 spec->mute_led_polarity, brightness); in coef_mute_led_set()
4688 struct alc_spec *spec = codec->spec; in alc285_fixup_hp_mute_led_coefbit()
4691 spec->mute_led_polarity = 0; in alc285_fixup_hp_mute_led_coefbit()
4692 spec->mute_led_coef.idx = 0x0b; in alc285_fixup_hp_mute_led_coefbit()
4693 spec->mute_led_coef.mask = 1 << 3; in alc285_fixup_hp_mute_led_coefbit()
4694 spec->mute_led_coef.on = 1 << 3; in alc285_fixup_hp_mute_led_coefbit()
4695 spec->mute_led_coef.off = 0; in alc285_fixup_hp_mute_led_coefbit()
4704 struct alc_spec *spec = codec->spec; in alc236_fixup_hp_mute_led_coefbit()
4707 spec->mute_led_polarity = 0; in alc236_fixup_hp_mute_led_coefbit()
4708 spec->mute_led_coef.idx = 0x34; in alc236_fixup_hp_mute_led_coefbit()
4709 spec->mute_led_coef.mask = 1 << 5; in alc236_fixup_hp_mute_led_coefbit()
4710 spec->mute_led_coef.on = 0; in alc236_fixup_hp_mute_led_coefbit()
4711 spec->mute_led_coef.off = 1 << 5; in alc236_fixup_hp_mute_led_coefbit()
4719 struct alc_spec *spec = codec->spec; in alc236_fixup_hp_mute_led_coefbit2()
4722 spec->mute_led_polarity = 0; in alc236_fixup_hp_mute_led_coefbit2()
4723 spec->mute_led_coef.idx = 0x07; in alc236_fixup_hp_mute_led_coefbit2()
4724 spec->mute_led_coef.mask = 1; in alc236_fixup_hp_mute_led_coefbit2()
4725 spec->mute_led_coef.on = 1; in alc236_fixup_hp_mute_led_coefbit2()
4726 spec->mute_led_coef.off = 0; in alc236_fixup_hp_mute_led_coefbit2()
4735 struct alc_spec *spec = codec->spec; in alc245_fixup_hp_mute_led_coefbit()
4738 spec->mute_led_polarity = 0; in alc245_fixup_hp_mute_led_coefbit()
4739 spec->mute_led_coef.idx = 0x0b; in alc245_fixup_hp_mute_led_coefbit()
4740 spec->mute_led_coef.mask = 3 << 2; in alc245_fixup_hp_mute_led_coefbit()
4741 spec->mute_led_coef.on = 2 << 2; in alc245_fixup_hp_mute_led_coefbit()
4742 spec->mute_led_coef.off = 1 << 2; in alc245_fixup_hp_mute_led_coefbit()
4751 struct alc_spec *spec = codec->spec; in alc245_fixup_hp_mute_led_v1_coefbit()
4754 spec->mute_led_polarity = 0; in alc245_fixup_hp_mute_led_v1_coefbit()
4755 spec->mute_led_coef.idx = 0x0b; in alc245_fixup_hp_mute_led_v1_coefbit()
4756 spec->mute_led_coef.mask = 3 << 2; in alc245_fixup_hp_mute_led_v1_coefbit()
4757 spec->mute_led_coef.on = 1 << 3; in alc245_fixup_hp_mute_led_v1_coefbit()
4758 spec->mute_led_coef.off = 0; in alc245_fixup_hp_mute_led_v1_coefbit()
4763 /* turn on/off mic-mute LED per capture hook by coef bit */
4767 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in coef_micmute_led_set()
4768 struct alc_spec *spec = codec->spec; in coef_micmute_led_set()
4770 alc_update_coef_led(codec, &spec->mic_led_coef, in coef_micmute_led_set()
4771 spec->micmute_led_polarity, brightness); in coef_micmute_led_set()
4778 struct alc_spec *spec = codec->spec; in alc285_fixup_hp_coef_micmute_led()
4781 spec->mic_led_coef.idx = 0x19; in alc285_fixup_hp_coef_micmute_led()
4782 spec->mic_led_coef.mask = 1 << 13; in alc285_fixup_hp_coef_micmute_led()
4783 spec->mic_led_coef.on = 1 << 13; in alc285_fixup_hp_coef_micmute_led()
4784 spec->mic_led_coef.off = 0; in alc285_fixup_hp_coef_micmute_led()
4792 struct alc_spec *spec = codec->spec; in alc285_fixup_hp_gpio_micmute_led()
4795 spec->micmute_led_polarity = 1; in alc285_fixup_hp_gpio_micmute_led()
4802 struct alc_spec *spec = codec->spec; in alc236_fixup_hp_coef_micmute_led()
4805 spec->mic_led_coef.idx = 0x35; in alc236_fixup_hp_coef_micmute_led()
4806 spec->mic_led_coef.mask = 3 << 2; in alc236_fixup_hp_coef_micmute_led()
4807 spec->mic_led_coef.on = 2 << 2; in alc236_fixup_hp_coef_micmute_led()
4808 spec->mic_led_coef.off = 1 << 2; in alc236_fixup_hp_coef_micmute_led()
4816 struct alc_spec *spec = codec->spec; in alc295_fixup_hp_mute_led_coefbit11()
4819 spec->mute_led_polarity = 0; in alc295_fixup_hp_mute_led_coefbit11()
4820 spec->mute_led_coef.idx = 0xb; in alc295_fixup_hp_mute_led_coefbit11()
4821 spec->mute_led_coef.mask = 3 << 3; in alc295_fixup_hp_mute_led_coefbit11()
4822 spec->mute_led_coef.on = 1 << 3; in alc295_fixup_hp_mute_led_coefbit11()
4823 spec->mute_led_coef.off = 1 << 4; in alc295_fixup_hp_mute_led_coefbit11()
4852 struct alc_spec *spec = codec->spec; in alc236_fixup_hp_micmute_led_vref()
4855 spec->cap_mute_led_nid = 0x1a; in alc236_fixup_hp_micmute_led_vref()
4857 codec->power_filter = led_power_filter; in alc236_fixup_hp_micmute_led_vref()
4952 struct alc_spec *spec = codec->spec; in alc298_samsung_v2_enable_amps()
4958 for (i = 0; i < spec->num_speaker_amps; i++) { in alc298_samsung_v2_enable_amps()
4969 struct alc_spec *spec = codec->spec; in alc298_samsung_v2_disable_amps()
4975 for (i = 0; i < spec->num_speaker_amps; i++) { in alc298_samsung_v2_disable_amps()
4999 struct alc_spec *spec = codec->spec; in alc298_samsung_v2_init_amps()
5003 spec->num_speaker_amps = num_speaker_amps; in alc298_samsung_v2_init_amps()
5009 for (i = 0; i < spec->num_speaker_amps; i++) { in alc298_samsung_v2_init_amps()
5021 spec->gen.pcm_playback_hook = alc298_samsung_v2_playback_hook; in alc298_samsung_v2_init_amps()
5041 struct alc_spec *spec = codec->spec; in gpio2_mic_hotkey_event()
5045 input_report_key(spec->kb_dev, spec->alc_mute_keycode_map[ALC_KEY_MICMUTE_INDEX], 1); in gpio2_mic_hotkey_event()
5046 input_sync(spec->kb_dev); in gpio2_mic_hotkey_event()
5047 input_report_key(spec->kb_dev, spec->alc_mute_keycode_map[ALC_KEY_MICMUTE_INDEX], 0); in gpio2_mic_hotkey_event()
5048 input_sync(spec->kb_dev); in gpio2_mic_hotkey_event()
5053 struct alc_spec *spec = codec->spec; in alc_register_micmute_input_device()
5056 spec->kb_dev = input_allocate_device(); in alc_register_micmute_input_device()
5057 if (!spec->kb_dev) { in alc_register_micmute_input_device()
5059 return -ENOMEM; in alc_register_micmute_input_device()
5062 spec->alc_mute_keycode_map[ALC_KEY_MICMUTE_INDEX] = KEY_MICMUTE; in alc_register_micmute_input_device()
5064 spec->kb_dev->name = "Microphone Mute Button"; in alc_register_micmute_input_device()
5065 spec->kb_dev->evbit[0] = BIT_MASK(EV_KEY); in alc_register_micmute_input_device()
5066 spec->kb_dev->keycodesize = sizeof(spec->alc_mute_keycode_map[0]); in alc_register_micmute_input_device()
5067 spec->kb_dev->keycodemax = ARRAY_SIZE(spec->alc_mute_keycode_map); in alc_register_micmute_input_device()
5068 spec->kb_dev->keycode = spec->alc_mute_keycode_map; in alc_register_micmute_input_device()
5069 for (i = 0; i < ARRAY_SIZE(spec->alc_mute_keycode_map); i++) in alc_register_micmute_input_device()
5070 set_bit(spec->alc_mute_keycode_map[i], spec->kb_dev->keybit); in alc_register_micmute_input_device()
5072 if (input_register_device(spec->kb_dev)) { in alc_register_micmute_input_device()
5074 input_free_device(spec->kb_dev); in alc_register_micmute_input_device()
5075 spec->kb_dev = NULL; in alc_register_micmute_input_device()
5076 return -ENOMEM; in alc_register_micmute_input_device()
5090 struct alc_spec *spec = codec->spec; in alc280_fixup_hp_gpio2_mic_hotkey()
5094 spec->init_amp = ALC_INIT_DEFAULT; in alc280_fixup_hp_gpio2_mic_hotkey()
5098 spec->gpio_mask |= 0x06; in alc280_fixup_hp_gpio2_mic_hotkey()
5099 spec->gpio_dir |= 0x02; in alc280_fixup_hp_gpio2_mic_hotkey()
5100 spec->gpio_data |= 0x02; in alc280_fixup_hp_gpio2_mic_hotkey()
5101 snd_hda_codec_write_cache(codec, codec->core.afg, 0, in alc280_fixup_hp_gpio2_mic_hotkey()
5103 snd_hda_jack_detect_enable_callback(codec, codec->core.afg, in alc280_fixup_hp_gpio2_mic_hotkey()
5108 if (!spec->kb_dev) in alc280_fixup_hp_gpio2_mic_hotkey()
5113 input_unregister_device(spec->kb_dev); in alc280_fixup_hp_gpio2_mic_hotkey()
5114 spec->kb_dev = NULL; in alc280_fixup_hp_gpio2_mic_hotkey()
5124 struct alc_spec *spec = codec->spec; in alc233_fixup_lenovo_line2_mic_hotkey()
5128 spec->init_amp = ALC_INIT_DEFAULT; in alc233_fixup_lenovo_line2_mic_hotkey()
5137 if (!spec->kb_dev) in alc233_fixup_lenovo_line2_mic_hotkey()
5142 input_unregister_device(spec->kb_dev); in alc233_fixup_lenovo_line2_mic_hotkey()
5143 spec->kb_dev = NULL; in alc233_fixup_lenovo_line2_mic_hotkey()
5150 struct alc_spec *spec = codec->spec; in alc269_fixup_hp_line1_mic1_led()
5154 spec->cap_mute_led_nid = 0x18; in alc269_fixup_hp_line1_mic1_led()
5162 struct alc_spec *spec = codec->spec; in alc233_fixup_lenovo_low_en_micmute_led()
5165 spec->micmute_led_polarity = 1; in alc233_fixup_lenovo_low_en_micmute_led()
5206 struct alc_spec *spec = codec->spec; in alc_headset_mode_unplugged()
5256 UPDATE_COEF(0x1a, 1<<3, 1<<3), /* Combo JD gating with LINE1-VREFO */ in alc_headset_mode_unplugged()
5258 UPDATE_COEF(0x4a, 0x000f, 0x000e), /* Combo Jack auto detect */ in alc_headset_mode_unplugged()
5281 if (spec->no_internal_mic_pin) { in alc_headset_mode_unplugged()
5286 switch (codec->core.vendor_id) { in alc_headset_mode_unplugged()
5337 codec_dbg(codec, "Headset jack set to unplugged mode.\n"); in alc_headset_mode_unplugged()
5379 UPDATE_COEF(0x1a, 1<<3, 0), /* Combo JD gating without LINE1-VREFO */ in alc_headset_mode_mic_in()
5401 switch (codec->core.vendor_id) { in alc_headset_mode_mic_in()
5477 codec_dbg(codec, "Headset jack set to mic-in mode.\n"); in alc_headset_mode_mic_in()
5527 UPDATE_COEF(0x4a, 0x000f, 0x000e), /* Combo Jack auto detect */ in alc_headset_mode_default()
5529 UPDATE_COEF(0x1a, 1<<3, 0), /* Combo JD gating without LINE1-VREFO */ in alc_headset_mode_default()
5546 switch (codec->core.vendor_id) { in alc_headset_mode_default()
5597 codec_dbg(codec, "Headset jack set to headphone (default) mode.\n"); in alc_headset_mode_default()
5657 switch (codec->core.vendor_id) { in alc_headset_mode_ctia()
5721 codec_dbg(codec, "Headset jack set to iPhone-style headset mode.\n"); in alc_headset_mode_ctia()
5774 switch (codec->core.vendor_id) { in alc_headset_mode_omtp()
5795 alc_update_coef_idx(codec, 0x8e, 0x0070, 0x0010);/* Headset output enable */ in alc_headset_mode_omtp()
5824 codec_dbg(codec, "Headset jack set to Nokia-style headset mode.\n"); in alc_headset_mode_omtp()
5831 struct alc_spec *spec = codec->spec; in alc_determine_headset_type()
5851 UPDATE_COEF(0x4a, 0x000f, 0x0008), /* Combo Jack auto detect */ in alc_determine_headset_type()
5870 if (spec->no_internal_mic_pin) { in alc_determine_headset_type()
5875 switch (codec->core.vendor_id) { in alc_determine_headset_type()
6016 codec_dbg(codec, "Headset jack detected iPhone-style headset: %s\n", in alc_determine_headset_type()
6018 spec->current_headset_type = is_ctia ? ALC_HEADSET_TYPE_CTIA : ALC_HEADSET_TYPE_OMTP; in alc_determine_headset_type()
6023 struct alc_spec *spec = codec->spec; in alc_update_headset_mode()
6025 hda_nid_t mux_pin = spec->gen.imux_pins[spec->gen.cur_mux[0]]; in alc_update_headset_mode()
6032 else if (mux_pin == spec->headset_mic_pin) in alc_update_headset_mode()
6034 else if (mux_pin == spec->headphone_mic_pin) in alc_update_headset_mode()
6039 if (new_headset_mode == spec->current_headset_mode) { in alc_update_headset_mode()
6047 spec->current_headset_mode = ALC_HEADSET_MODE_UNKNOWN; in alc_update_headset_mode()
6048 spec->current_headset_type = ALC_HEADSET_TYPE_UNKNOWN; in alc_update_headset_mode()
6049 spec->gen.hp_jack_present = false; in alc_update_headset_mode()
6052 if (spec->current_headset_type == ALC_HEADSET_TYPE_UNKNOWN) in alc_update_headset_mode()
6054 if (spec->current_headset_type == ALC_HEADSET_TYPE_CTIA) in alc_update_headset_mode()
6056 else if (spec->current_headset_type == ALC_HEADSET_TYPE_OMTP) in alc_update_headset_mode()
6058 spec->gen.hp_jack_present = true; in alc_update_headset_mode()
6061 alc_headset_mode_mic_in(codec, hp_pin, spec->headphone_mic_pin); in alc_update_headset_mode()
6062 spec->gen.hp_jack_present = false; in alc_update_headset_mode()
6066 spec->gen.hp_jack_present = true; in alc_update_headset_mode()
6072 if (spec->headphone_mic_pin && spec->headphone_mic_pin != hp_pin) in alc_update_headset_mode()
6073 snd_hda_set_pin_ctl_cache(codec, spec->headphone_mic_pin, in alc_update_headset_mode()
6076 spec->current_headset_mode = new_headset_mode; in alc_update_headset_mode()
6098 struct alc_spec *spec = codec->spec; in alc_probe_headset_mode()
6099 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in alc_probe_headset_mode()
6102 for (i = 0; i < cfg->num_inputs; i++) { in alc_probe_headset_mode()
6103 if (cfg->inputs[i].is_headset_mic && !spec->headset_mic_pin) in alc_probe_headset_mode()
6104 spec->headset_mic_pin = cfg->inputs[i].pin; in alc_probe_headset_mode()
6105 if (cfg->inputs[i].is_headphone_mic && !spec->headphone_mic_pin) in alc_probe_headset_mode()
6106 spec->headphone_mic_pin = cfg->inputs[i].pin; in alc_probe_headset_mode()
6109 WARN_ON(spec->gen.cap_sync_hook); in alc_probe_headset_mode()
6110 spec->gen.cap_sync_hook = alc_update_headset_mode_hook; in alc_probe_headset_mode()
6111 spec->gen.automute_hook = alc_update_headset_mode; in alc_probe_headset_mode()
6112 spec->gen.hp_automute_hook = alc_update_headset_jack_cb; in alc_probe_headset_mode()
6118 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode()
6122 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC | HDA_PINCFG_HEADPHONE_MIC; in alc_fixup_headset_mode()
6129 spec->current_headset_mode = ALC_HEADSET_MODE_UNKNOWN; in alc_fixup_headset_mode()
6130 spec->current_headset_type = ALC_HEADSET_TYPE_UNKNOWN; in alc_fixup_headset_mode()
6141 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode_no_hp_mic()
6142 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc_fixup_headset_mode_no_hp_mic()
6167 switch (codec->core.vendor_id) { in alc255_set_default_jack_type()
6194 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode_alc255_no_hp_mic()
6195 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc_fixup_headset_mode_alc255_no_hp_mic()
6205 struct alc_spec *spec = codec->spec; in alc288_update_headset_jack_cb()
6208 /* Headset Mic enable or disable, only for Dell Dino */ in alc288_update_headset_jack_cb()
6209 alc_update_gpio_data(codec, 0x40, spec->gen.hp_jack_present); in alc288_update_headset_jack_cb()
6217 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode_dell_alc288()
6219 spec->gpio_mask |= 0x40; in alc_fixup_headset_mode_dell_alc288()
6220 spec->gpio_dir |= 0x40; in alc_fixup_headset_mode_dell_alc288()
6221 spec->gen.hp_automute_hook = alc288_update_headset_jack_cb; in alc_fixup_headset_mode_dell_alc288()
6229 struct alc_spec *spec = codec->spec; in alc_fixup_auto_mute_via_amp()
6230 spec->gen.auto_mute_via_amp = 1; in alc_fixup_auto_mute_via_amp()
6238 struct alc_spec *spec = codec->spec; in alc_fixup_no_shutup()
6239 spec->no_shutup_pins = 1; in alc_fixup_no_shutup()
6247 struct alc_spec *spec = codec->spec; in alc_fixup_disable_aamix()
6248 /* Disable AA-loopback as it causes white noise */ in alc_fixup_disable_aamix()
6249 spec->gen.mixer_nid = 0; in alc_fixup_disable_aamix()
6262 struct alc_spec *spec = codec->spec; in alc_fixup_tpt440_dock()
6265 spec->parse_flags = HDA_PINCFG_NO_HP_FIXUP; in alc_fixup_tpt440_dock()
6266 codec->power_save_node = 0; /* avoid click noises */ in alc_fixup_tpt440_dock()
6279 struct alc_spec *spec = codec->spec; in alc_fixup_tpt470_dock()
6282 spec->parse_flags = HDA_PINCFG_NO_HP_FIXUP; in alc_fixup_tpt470_dock()
6305 struct alc_spec *spec = codec->spec; in alc_fixup_tpt470_dacs()
6308 spec->gen.preferred_dacs = preferred_pairs; in alc_fixup_tpt470_dacs()
6317 struct alc_spec *spec = codec->spec; in alc295_fixup_asus_dacs()
6320 spec->gen.preferred_dacs = preferred_pairs; in alc295_fixup_asus_dacs()
6325 struct alc_spec *spec = codec->spec; in alc_shutup_dell_xps13()
6337 struct alc_spec *spec = codec->spec; in alc_fixup_dell_xps13()
6338 struct hda_input_mux *imux = &spec->gen.input_mux; in alc_fixup_dell_xps13()
6343 /* mic pin 0x19 must be initialized with Vref Hi-Z, otherwise in alc_fixup_dell_xps13()
6347 spec->shutup = alc_shutup_dell_xps13; in alc_fixup_dell_xps13()
6351 for (i = 0; i < imux->num_items; i++) { in alc_fixup_dell_xps13()
6352 if (spec->gen.imux_pins[i] == 0x12) { in alc_fixup_dell_xps13()
6353 spec->gen.cur_mux[0] = i; in alc_fixup_dell_xps13()
6364 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode_alc662()
6367 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc_fixup_headset_mode_alc662()
6368 spec->gen.hp_mic = 1; /* Mic-in is same pin as headphone */ in alc_fixup_headset_mode_alc662()
6370 /* Disable boost for mic-in permanently. (This code is only called in alc_fixup_headset_mode_alc662()
6392 struct alc_spec *spec = codec->spec; in find_ext_mic_pin()
6393 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in find_ext_mic_pin()
6398 for (i = 0; i < cfg->num_inputs; i++) { in find_ext_mic_pin()
6399 if (cfg->inputs[i].type != AUTO_PIN_MIC) in find_ext_mic_pin()
6401 nid = cfg->inputs[i].pin; in find_ext_mic_pin()
6415 struct alc_spec *spec = codec->spec; in alc271_hp_gate_mic_jack()
6431 struct alc_spec *spec = codec->spec; in alc269_fixup_limit_int_mic_boost()
6432 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in alc269_fixup_limit_int_mic_boost()
6442 for (i = 0; i < cfg->num_inputs; i++) { in alc269_fixup_limit_int_mic_boost()
6443 hda_nid_t nid = cfg->inputs[i].pin; in alc269_fixup_limit_int_mic_boost()
6445 if (cfg->inputs[i].type != AUTO_PIN_MIC) in alc269_fixup_limit_int_mic_boost()
6462 struct alc_spec *spec = codec->spec; in alc283_hp_automute_hook()
6468 vref = spec->gen.hp_jack_present ? PIN_VREF80 : 0; in alc283_hp_automute_hook()
6478 struct alc_spec *spec = codec->spec; in alc283_fixup_chromebook()
6483 /* Disable AA-loopback as it causes white noise */ in alc283_fixup_chromebook()
6484 spec->gen.mixer_nid = 0; in alc283_fixup_chromebook()
6487 /* MIC2-VREF control */ in alc283_fixup_chromebook()
6499 struct alc_spec *spec = codec->spec; in alc283_fixup_sense_combo_jack()
6503 spec->gen.hp_automute_hook = alc283_hp_automute_hook; in alc283_fixup_sense_combo_jack()
6506 /* MIC2-VREF control */ in alc283_fixup_sense_combo_jack()
6516 struct alc_spec *spec = codec->spec; in asus_tx300_automute()
6519 spec->gen.mute_bits |= (1ULL << 0x14); in asus_tx300_automute()
6525 struct alc_spec *spec = codec->spec; in alc282_fixup_asus_tx300()
6533 spec->init_amp = ALC_INIT_DEFAULT; in alc282_fixup_asus_tx300()
6537 spec->gen.auto_mute_via_amp = 1; in alc282_fixup_asus_tx300()
6538 spec->gen.automute_hook = asus_tx300_automute; in alc282_fixup_asus_tx300()
6543 spec->init_amp = ALC_INIT_DEFAULT; in alc282_fixup_asus_tx300()
6576 Amp-out capability. we change the speaker's route to: in alc298_fixup_speaker_volume()
6577 Node 0x02 (Audio Output) -> Node 0x0c (Audio Mixer) -> Node 0x17 ( in alc298_fixup_speaker_volume()
6578 Pin Complex), since Node 0x02 has Amp-out caps, we can adjust in alc298_fixup_speaker_volume()
6606 /* disable DAC3 (0x06) selection on NID 0x15 - share Speaker/Bass Speaker DAC 0x03 */
6621 struct alc_spec *spec = codec->spec; in alc280_hp_gpio4_automute_hook()
6625 alc_update_gpio_led(codec, 0x10, spec->mute_led_polarity, in alc280_hp_gpio4_automute_hook()
6626 !spec->gen.hp_jack_present); in alc280_hp_gpio4_automute_hook()
6629 /* Manage GPIOs for HP EliteBook Folio 9480m.
6639 struct alc_spec *spec = codec->spec; in alc280_fixup_hp_9480m()
6644 spec->gpio_mask |= 0x10; in alc280_fixup_hp_9480m()
6645 spec->gpio_dir |= 0x10; in alc280_fixup_hp_9480m()
6646 spec->gen.hp_automute_hook = alc280_hp_gpio4_automute_hook; in alc280_fixup_hp_9480m()
6654 struct alc_spec *spec = codec->spec; in alc275_fixup_gpio4_off()
6657 spec->gpio_mask |= 0x04; in alc275_fixup_gpio4_off()
6658 spec->gpio_dir |= 0x04; in alc275_fixup_gpio4_off()
6665 * DAC1 (NID 0x02) -> Speaker (NID 0x14); some eq applied secretly
6666 * DAC2 (NID 0x03) -> Bass (NID 0x17) & Headphone (NID 0x21); sharing a DAC
6667 * DAC3 (NID 0x06) -> Unused, due to the lack of volume amp
6676 struct alc_spec *spec = codec->spec; in alc285_fixup_thinkpad_x1_gen7()
6681 spec->gen.preferred_dacs = preferred_pairs; in alc285_fixup_thinkpad_x1_gen7()
6704 strcpy(codec->card->longname, "HDAudio-Lenovo-DualCodecs"); in alc233_alc662_fixup_lenovo_dual_codecs()
6709 codec->addr == 0 ? in alc233_alc662_fixup_lenovo_dual_codecs()
6710 "Rear-Panel Capture Volume" : in alc233_alc662_fixup_lenovo_dual_codecs()
6711 "Front-Panel Capture Volume"); in alc233_alc662_fixup_lenovo_dual_codecs()
6713 codec->addr == 0 ? in alc233_alc662_fixup_lenovo_dual_codecs()
6714 "Rear-Panel Capture Switch" : in alc233_alc662_fixup_lenovo_dual_codecs()
6715 "Front-Panel Capture Switch"); in alc233_alc662_fixup_lenovo_dual_codecs()
6726 codec->power_save_node = 1; in alc225_fixup_s3_pop_noise()
6733 struct alc_spec *spec = codec->spec; in alc274_fixup_bind_dacs()
6742 spec->gen.preferred_dacs = preferred_pairs; in alc274_fixup_bind_dacs()
6743 spec->gen.auto_mute_via_amp = 1; in alc274_fixup_bind_dacs()
6744 codec->power_save_node = 0; in alc274_fixup_bind_dacs()
6754 * Amp-out capability. Assure the speaker and lineout pin to be in alc274_fixup_hp_aio_bind_dacs()
6760 struct alc_spec *spec = codec->spec; in alc274_fixup_hp_aio_bind_dacs()
6763 spec->gen.preferred_dacs = preferred_pairs; in alc274_fixup_hp_aio_bind_dacs()
6773 struct alc_spec *spec = codec->spec; in alc289_fixup_asus_ga401()
6776 spec->gen.preferred_dacs = preferred_pairs; in alc289_fixup_asus_ga401()
6791 switch (codec->core.vendor_id) { in alc_combo_jack_hp_jd_restart()
6816 struct alc_spec *spec = codec->spec; in alc295_fixup_chromebook()
6820 spec->ultra_low_power = true; in alc295_fixup_chromebook()
6831 struct alc_spec *spec = codec->spec; in alc256_fixup_chromebook()
6835 if (codec->core.subsystem_id == 0x10280d76) in alc256_fixup_chromebook()
6836 spec->gen.suppress_auto_mute = 0; in alc256_fixup_chromebook()
6838 spec->gen.suppress_auto_mute = 1; in alc256_fixup_chromebook()
6839 spec->gen.suppress_auto_mic = 1; in alc256_fixup_chromebook()
6840 spec->en_3kpull_low = false; in alc256_fixup_chromebook()
6868 /* Pin 0x21: headphones/headset mic */ in alc294_fixup_gx502_hp()
6938 struct alc_spec *spec = codec->spec; in alc_fixup_no_int_mic()
6944 spec->no_internal_mic_pin = true; in alc_fixup_no_int_mic()
6960 struct alc_spec *spec = codec->spec; in alc285_fixup_hp_spectre_x360_eb1()
6972 spec->micmute_led_polarity = 1; in alc285_fixup_hp_spectre_x360_eb1()
6974 spec->gpio_mask |= 0x01; in alc285_fixup_hp_spectre_x360_eb1()
6975 spec->gpio_dir |= 0x01; in alc285_fixup_hp_spectre_x360_eb1()
6995 struct alc_spec *spec = codec->spec; in alc285_fixup_hp_spectre_x360_df1()
7009 spec->gpio_mask |= 0x01; in alc285_fixup_hp_spectre_x360_df1()
7010 spec->gpio_dir |= 0x01; in alc285_fixup_hp_spectre_x360_df1()
7063 { 0x19, 0x03a11040 }, /* Headset microphone */ in alc285_fixup_hp_envy_x360()
7074 /* Fixes no sound from headset speaker */ in alc285_fixup_hp_envy_x360()
7075 snd_hda_codec_amp_stereo(codec, 0x21, HDA_OUTPUT, 0, -1, 0); in alc285_fixup_hp_envy_x360()
7077 /* Auto-enable headset mic when plugged */ in alc285_fixup_hp_envy_x360()
7080 /* Headset mic volume enhancement */ in alc285_fixup_hp_envy_x360()
7088 "B&O-Tuned Playback Volume"); in alc285_fixup_hp_envy_x360()
7101 codec->beep_just_power_on = true; in alc285_fixup_hp_beep()
7140 /* Fixup for Lenovo Legion 15IMHg05 speaker output on headset removal. */
7145 struct alc_spec *spec = codec->spec; in alc287_fixup_legion_15imhg05_speakers()
7149 spec->gen.suppress_auto_mute = 1; in alc287_fixup_legion_15imhg05_speakers()
7157 struct alc_spec *spec = cdc->spec; in comp_acpi_device_notify()
7161 hda_component_acpi_device_notify(&spec->comps, handle, event, data); in comp_acpi_device_notify()
7167 struct alc_spec *spec = cdc->spec; in comp_bind()
7170 ret = hda_component_manager_bind(cdc, &spec->comps); in comp_bind()
7175 &spec->comps, in comp_bind()
7182 struct alc_spec *spec = cdc->spec; in comp_unbind()
7184 hda_component_manager_unbind_acpi_notifications(cdc, &spec->comps, comp_acpi_device_notify); in comp_unbind()
7185 hda_component_manager_unbind(cdc, &spec->comps); in comp_unbind()
7196 struct alc_spec *spec = cdc->spec; in comp_generic_playback_hook()
7198 hda_component_manager_playback_hook(&spec->comps, action); in comp_generic_playback_hook()
7204 struct alc_spec *spec = cdc->spec; in comp_generic_fixup()
7209 ret = hda_component_manager_init(cdc, &spec->comps, count, bus, hid, in comp_generic_fixup()
7214 spec->gen.pcm_playback_hook = comp_generic_playback_hook; in comp_generic_fixup()
7217 hda_component_manager_free(&spec->comps, &comp_master_ops); in comp_generic_fixup()
7231 } acpi_ids[] = {{ "CSC3554", "cs35l54-hda" }, in find_cirrus_companion_amps()
7232 { "CSC3556", "cs35l56-hda" }, in find_cirrus_companion_amps()
7233 { "CSC3557", "cs35l57-hda" }}; in find_cirrus_companion_amps()
7238 adev = acpi_dev_get_first_match_dev(acpi_ids[i].hid, NULL, -1); in find_cirrus_companion_amps()
7270 * When available the cirrus,dev-index property is an accurate in find_cirrus_companion_amps()
7275 count_devindex = fwnode_property_count_u32(fwnode, "cirrus,dev-index"); in find_cirrus_companion_amps()
7279 match = devm_kasprintf(dev, GFP_KERNEL, "-%%s:00-%s.%%d", acpi_ids[i].name); in find_cirrus_companion_amps()
7288 comp_generic_fixup(cdc, action, "i2c", "CSC3551", "-%s:00-cs35l41-hda.%d", 2); in cs35l41_fixup_i2c_two()
7293 comp_generic_fixup(cdc, action, "i2c", "CSC3551", "-%s:00-cs35l41-hda.%d", 4); in cs35l41_fixup_i2c_four()
7298 comp_generic_fixup(codec, action, "spi", "CSC3551", "-%s:00-cs35l41-hda.%d", 2); in cs35l41_fixup_spi_two()
7303 comp_generic_fixup(codec, action, "spi", "CSC3551", "-%s:00-cs35l41-hda.%d", 4); in cs35l41_fixup_spi_four()
7309 comp_generic_fixup(cdc, action, "i2c", "CLSA0100", "-%s:00-cs35l41-hda.%d", 2); in alc287_fixup_legion_16achg6_speakers()
7315 comp_generic_fixup(cdc, action, "i2c", "CLSA0101", "-%s:00-cs35l41-hda.%d", 2); in alc287_fixup_legion_16ithg6_speakers()
7321 * The same SSID has been re-used in different hardware, they have in alc285_fixup_asus_ga403u()
7324 if (cdc->core.vendor_id != 0x10ec0285) in alc285_fixup_asus_ga403u()
7331 comp_generic_fixup(cdc, action, "i2c", "TIAS2781", "-%s:00", 1); in tas2781_fixup_i2c()
7336 comp_generic_fixup(cdc, action, "spi", "TXNW2781", "-%s:00-tas2781-hda.%d", 2); in tas2781_fixup_spi()
7342 comp_generic_fixup(cdc, action, "i2c", "INT8866", "-%s:00", 1); in yoga7_14arb7_fixup_i2c()
7374 * plugged-in state, while the internal microphone is always in an in alc256_fixup_set_coef_defaults()
7410 if (codec->core.vendor_id == 0x10ec0256) { in alc256_fixup_mic_no_presence_and_resume()
7428 nsteps = ((caps & AC_AMPCAP_NUM_STEPS) >> AC_AMPCAP_NUM_STEPS_SHIFT) - 10; in alc256_decrease_headphone_amp_val()
7429 offs = ((caps & AC_AMPCAP_OFFSET) >> AC_AMPCAP_OFFSET_SHIFT) - 10; in alc256_decrease_headphone_amp_val()
7441 struct alc_spec *spec = codec->spec; in alc_fixup_dell4_mic_no_presence_quiet()
7442 struct hda_input_mux *imux = &spec->gen.input_mux; in alc_fixup_dell4_mic_no_presence_quiet()
7450 * Set the vref of pin 0x19 (Headset Mic) and pin 0x1b (Headphone Mic) in alc_fixup_dell4_mic_no_presence_quiet()
7451 * to Hi-Z to avoid pop noises at startup and when plugging and in alc_fixup_dell4_mic_no_presence_quiet()
7462 for (i = 0; i < imux->num_items; i++) { in alc_fixup_dell4_mic_no_presence_quiet()
7463 if (spec->gen.imux_pins[i] == 0x12) { in alc_fixup_dell4_mic_no_presence_quiet()
7464 spec->gen.cur_mux[0] = i; in alc_fixup_dell4_mic_no_presence_quiet()
7498 struct alc_spec *spec = codec->spec; in alc287_fixup_yoga9_14iap7_bass_spk_pin()
7507 spec->gen.preferred_dacs = preferred_pairs; in alc287_fixup_yoga9_14iap7_bass_spk_pin()
7527 struct alc_spec *spec = codec->spec; in alc295_fixup_dell_inspiron_top_speakers()
7535 spec->gen.preferred_dacs = preferred_pairs; in alc295_fixup_dell_inspiron_top_speakers()
7544 struct alc_spec *spec = codec->spec; in alc287_fixup_bind_dacs()
7554 spec->gen.preferred_dacs = preferred_pairs; in alc287_fixup_bind_dacs()
7555 spec->gen.auto_mute_via_amp = 1; in alc287_fixup_bind_dacs()
7556 if (spec->gen.autocfg.speaker_pins[0] != 0x14) { in alc287_fixup_bind_dacs()
7561 /* Fix none verb table of Headset Mic pin */
7565 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mic()
7575 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc_fixup_headset_mic()
7622 struct alc_spec *spec = codec->spec; in alc245_fixup_hp_spectre_x360_16_aa0xxx()
7637 spec->gpio_mask |= 0x01; in alc245_fixup_hp_spectre_x360_16_aa0xxx()
7638 spec->gpio_dir |= 0x01; in alc245_fixup_hp_spectre_x360_16_aa0xxx()
7658 struct alc_spec *spec = codec->spec; in alc245_fixup_hp_zbook_firefly_g12a()
7663 spec->gen.auto_mute_via_amp = 1; in alc245_fixup_hp_zbook_firefly_g12a()
7701 struct alc_spec *spec = codec->spec; in alc287_fixup_lenovo_thinkpad_with_alc1318()
7713 spec->power_hook = alc287_s4_power_gpio3_default; in alc287_fixup_lenovo_thinkpad_with_alc1318()
7714 spec->gen.pcm_playback_hook = alc287_alc1318_playback_pcm_hook; in alc287_fixup_lenovo_thinkpad_with_alc1318()
8053 if (codec->core.vendor_id == 0x10ec0298) in alc298_fixup_lenovo_c940_duet7()
8165 { 0x1a, 0x2101103f }, /* dock line-out */
8166 { 0x1b, 0x23a11040 }, /* dock mic-in */
8175 { 0x19, 0x01a1903c }, /* headset mic, with jack detect */
8216 { 0x18, 0x03a19020 }, /* headset mic */
8227 { 0x19, 0x99a3092f }, /* int-mic */
8234 { 0x12, 0x99a3092f }, /* int-mic */
8246 { 0x19, 0x99a3092f }, /* int-mic */
8254 { 0x12, 0x99a3092f }, /* int-mic */
8324 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8325 { 0x1a, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
8342 { 0x1a, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8351 { 0x1a, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8360 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8361 { 0x1b, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
8380 { 0x19, 0x01a1913c }, /* headset mic w/o jack detect */
8389 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8437 { 0x18, 0x04a1182c }, /* Headset mic */
8448 { 0x1b, 0x99a7012f }, /* int-mic */
8468 { 0x12, 0x99a3092f }, /* int-mic */
8493 /* class-D output amp +5dB */
8504 { 0x18, 0x01a110f0 }, /* use as headset mic */
8519 { 0x12, 0x99a3092f }, /* int-mic */
8598 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8607 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8616 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8617 { 0x1a, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
8632 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8651 { 0x18, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
8652 { 0x1a, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8716 { 0x1b, 0x21011020 }, /* line-out */
8717 { 0x1a, 0x01a1903c }, /* headset mic */
8718 { 0x18, 0x2181103f }, /* line-in */
8727 { 0x1b, 0x21011020 }, /* line-out */
8728 { 0x18, 0x2181103f }, /* line-in */
8753 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8754 { 0x1a, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
8800 { 0x18, 0x01a1913c }, /* headset mic w/o jack detect */
8809 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8810 { 0x1a, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
8819 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8875 /* Disable pass-through path for FRONT 14h */
8981 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8982 { 0x1a, 0x01813030 }, /* use as headphone mic, without its own jack detect */
8991 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
8992 { 0x1a, 0x01a1913d }, /* use as headphone mic, without its own jack detect */
9006 { 0x19, 0x04a11120 }, /* use as headset mic, without its own jack detect */
9020 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
9068 { 0x16, 0x0101102f }, /* Rear Headset HP */
9069 { 0x19, 0x02a1913c }, /* use as Front headset mic, without its own jack detect */
9070 { 0x1a, 0x01a19030 }, /* Rear Headset MIC */
9137 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
9171 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
9181 { 0x19, 0x04a11120 }, /* use as headset mic, without its own jack detect */
9190 { 0x19, 0x01a1103c }, /* use as headset mic */
9222 { 0x1a, 0x01a1913c }, /* use as headset mic, without its own jack detect */
9231 /* Disable PCBEEP-IN passthrough */
9253 { 0x19, 0x01a1913c }, /* use as Front headset mic, without its own jack detect */
9284 { 0x19, 0x03a11020 }, /* headset mic with jack detect */
9293 { 0x19, 0x04a11120 }, /* use as headset mic, without its own jack detect */
9309 { 0x21, 0x90170150 }, /* use as headset mic, without its own jack detect */
9450 /* set 0x15 to HP-OUT ctrl */
9477 /* set 0x15 to HP-OUT ctrl */
9481 /* set 0x1b to HP-OUT */
9507 { 0x1e, 0x90170151 }, /* Rear jack, IN OUT EAPD Detect */
9601 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
9611 { 0x18, 0x02a111f0 }, /* use as headset mic, without its own jack detect */
9621 { 0x18, 0x02a11030 }, /* use as headset mic */
9630 { 0x18, 0x01a11130 }, /* use as headset mic, without its own jack detect */
9645 { 0x19, 0x03a11020 }, /* headset mic with jack detect */
9652 { 0x19, 0x02a11120 }, /* use as headset mic, without its own jack detect */
9750 { 0x1b, 0x01a1913c }, /* use as headset mic, without its own jack detect */
9759 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
9848 { 0x18, 0x01a1913c }, /* use as headset mic, without its own jack detect */
9863 { 0x19, 0x02a1113c }, /* use as headset mic, without its own jack detect */
10085 { 0x19, 0x03a11120 }, /* use as headset mic, without its own jack detect */
10158 { 0x19, 0x02a1112c }, /* use as headset mic, without its own jack detect */
10393 { 0x19, 0x03a1113c }, /* use as headset mic, without its own jack detect */
10452 SND_PCI_QUIRK(0x1025, 0x072d, "Acer Aspire V5-571G", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
10455 SND_PCI_QUIRK(0x1025, 0x0762, "Acer Aspire E1-472", ALC271_FIXUP_HP_GATE_MIC_JACK_E1_572),
10456 SND_PCI_QUIRK(0x1025, 0x0775, "Acer Aspire E1-572", ALC271_FIXUP_HP_GATE_MIC_JACK_E1_572),
10457 SND_PCI_QUIRK(0x1025, 0x079b, "Acer Aspire V5-573G", ALC282_FIXUP_ASPIRE_V5_PINS),
10458 SND_PCI_QUIRK(0x1025, 0x080d, "Acer Aspire V5-122P", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
10460 SND_PCI_QUIRK(0x1025, 0x100c, "Acer Aspire E5-574G", ALC255_FIXUP_ACER_LIMIT_INT_MIC_BOOST),
10462 SND_PCI_QUIRK(0x1025, 0x102b, "Acer Aspire C24-860", ALC286_FIXUP_ACER_AIO_MIC_NO_PRESENCE),
10463 SND_PCI_QUIRK(0x1025, 0x1065, "Acer Aspire C20-820", ALC269VC_FIXUP_ACER_HEADSET_MIC),
10465 SND_PCI_QUIRK(0x1025, 0x1094, "Acer Aspire E5-575T", ALC255_FIXUP_ACER_LIMIT_INT_MIC_BOOST),
10466 SND_PCI_QUIRK(0x1025, 0x1099, "Acer Aspire E5-523G", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
10467 SND_PCI_QUIRK(0x1025, 0x110e, "Acer Aspire ES1-432", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
10470 SND_PCI_QUIRK(0x1025, 0x1177, "Acer Predator G9-593", ALC255_FIXUP_PREDATOR_SUBWOOFER),
10471 SND_PCI_QUIRK(0x1025, 0x1178, "Acer Predator G9-593", ALC255_FIXUP_PREDATOR_SUBWOOFER),
10475 SND_PCI_QUIRK(0x1025, 0x1269, "Acer SWIFT SF314-54", ALC256_FIXUP_ACER_HEADSET_MIC),
10476 SND_PCI_QUIRK(0x1025, 0x126a, "Acer Swift SF114-32", ALC256_FIXUP_ACER_MIC_NO_PRESENCE),
10480 SND_PCI_QUIRK(0x1025, 0x129c, "Acer SWIFT SF314-55", ALC256_FIXUP_ACER_HEADSET_MIC),
10481 SND_PCI_QUIRK(0x1025, 0x129d, "Acer SWIFT SF313-51", ALC256_FIXUP_ACER_MIC_NO_PRESENCE),
10482 SND_PCI_QUIRK(0x1025, 0x1300, "Acer SWIFT SF314-56", ALC256_FIXUP_ACER_MIC_NO_PRESENCE),
10483 SND_PCI_QUIRK(0x1025, 0x1308, "Acer Aspire Z24-890", ALC286_FIXUP_ACER_AIO_HEADSET_MIC),
10484 SND_PCI_QUIRK(0x1025, 0x132a, "Acer TravelMate B114-21", ALC233_FIXUP_ACER_HEADSET_MIC),
10485 SND_PCI_QUIRK(0x1025, 0x1330, "Acer TravelMate X514-51T", ALC255_FIXUP_ACER_HEADSET_MIC),
10487 SND_PCI_QUIRK(0x1025, 0x141f, "Acer Spin SP513-54N", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
10488 SND_PCI_QUIRK(0x1025, 0x142b, "Acer Swift SF314-42", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
10489 SND_PCI_QUIRK(0x1025, 0x1430, "Acer TravelMate B311R-31", ALC256_FIXUP_ACER_MIC_NO_PRESENCE),
10490 SND_PCI_QUIRK(0x1025, 0x1466, "Acer Aspire A515-56", ALC255_FIXUP_ACER_HEADPHONE_AND_MIC),
10491 SND_PCI_QUIRK(0x1025, 0x1534, "Acer Predator PH315-54", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
10492 SND_PCI_QUIRK(0x1025, 0x159c, "Acer Nitro 5 AN515-58", ALC2XX_FIXUP_HEADSET_MIC),
10560 …SND_PCI_QUIRK(0x1028, 0x0b37, "Dell Inspiron 16 Plus 7620 2-in-1", ALC295_FIXUP_DELL_INSPIRON_TOP_…
10564 SND_PCI_QUIRK(0x1028, 0x0c0b, "Dell Oasis 14 RPL-P", ALC289_FIXUP_RTK_AMP_DUAL_SPK),
10577 SND_PCI_QUIRK(0x1028, 0x0cbd, "Dell Oasis 13 CS MTL-U", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10578 SND_PCI_QUIRK(0x1028, 0x0cbe, "Dell Oasis 13 2-IN-1 MTL-U", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10579 SND_PCI_QUIRK(0x1028, 0x0cbf, "Dell Oasis 13 Low Weight MTU-L", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10581 SND_PCI_QUIRK(0x1028, 0x0cc1, "Dell Oasis 14 MTL-H/U", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10582 SND_PCI_QUIRK(0x1028, 0x0cc2, "Dell Oasis 14 2-in-1 MTL-H/U", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10583 SND_PCI_QUIRK(0x1028, 0x0cc3, "Dell Oasis 14 Low Weight MTL-U", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10584 SND_PCI_QUIRK(0x1028, 0x0cc4, "Dell Oasis 16 MTL-H/U", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10657 SND_PCI_QUIRK(0x103c, 0x841c, "HP Pavilion 15-CK0xx", ALC269_FIXUP_HP_MUTE_LED_MIC3),
10660 SND_PCI_QUIRK(0x103c, 0x84ae, "HP 15-db0403ng", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10661 SND_PCI_QUIRK(0x103c, 0x84da, "HP OMEN dc0019-ur", ALC295_FIXUP_HP_OMEN),
10663 SND_PCI_QUIRK(0x103c, 0x8519, "HP Spectre x360 15-df0xxx", ALC285_FIXUP_HP_SPECTRE_X360),
10665 …SND_PCI_QUIRK(0x103c, 0x85c6, "HP Pavilion x360 Convertible 14-dy1xxx", ALC295_FIXUP_HP_MUTE_LED_C…
10666 SND_PCI_QUIRK(0x103c, 0x85de, "HP Envy x360 13-ar0xxx", ALC285_FIXUP_HP_ENVY_X360),
10670 SND_PCI_QUIRK(0x103c, 0x86c1, "HP Laptop 15-da3001TU", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10672 SND_PCI_QUIRK(0x103c, 0x86e7, "HP Spectre x360 15-eb0xxx", ALC285_FIXUP_HP_SPECTRE_X360_EB1),
10673 SND_PCI_QUIRK(0x103c, 0x863e, "HP Spectre x360 15-df1xxx", ALC285_FIXUP_HP_SPECTRE_X360_DF1),
10674 SND_PCI_QUIRK(0x103c, 0x86e8, "HP Spectre x360 15-eb0xxx", ALC285_FIXUP_HP_SPECTRE_X360_EB1),
10675 SND_PCI_QUIRK(0x103c, 0x86f9, "HP Spectre x360 13-aw0xxx", ALC285_FIXUP_HP_SPECTRE_X360_MUTE_LED),
10685 …SND_PCI_QUIRK(0x103c, 0x876e, "HP ENVY x360 Convertible 13-ay0xxx", ALC245_FIXUP_HP_X360_MUTE_LEDS…
10695 SND_PCI_QUIRK(0x103c, 0x87b7, "HP Laptop 14-fq0xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10697 SND_PCI_QUIRK(0x103c, 0x87cc, "HP Pavilion 15-eg0xxx", ALC287_FIXUP_HP_GPIO_LED),
10698 SND_PCI_QUIRK(0x103c, 0x87d3, "HP Laptop 15-gw0xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10708 SND_PCI_QUIRK(0x103c, 0x87fd, "HP Laptop 14-dq2xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10709 SND_PCI_QUIRK(0x103c, 0x87fe, "HP Laptop 15s-fq2xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10712 SND_PCI_QUIRK(0x103c, 0x8811, "HP Spectre x360 15-eb1xxx", ALC285_FIXUP_HP_SPECTRE_X360_EB1),
10713 SND_PCI_QUIRK(0x103c, 0x8812, "HP Spectre x360 15-eb1xxx", ALC285_FIXUP_HP_SPECTRE_X360_EB1),
10715 SND_PCI_QUIRK(0x103c, 0x881e, "HP Laptop 15s-du3xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10725 SND_PCI_QUIRK(0x103c, 0x887a, "HP Laptop 15s-eq2xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10726 SND_PCI_QUIRK(0x103c, 0x887c, "HP Laptop 14s-fq1xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10727 …SND_PCI_QUIRK(0x103c, 0x888a, "HP ENVY x360 Convertible 15-eu0xxx", ALC245_FIXUP_HP_X360_MUTE_LEDS…
10732 SND_PCI_QUIRK(0x103c, 0x88d0, "HP Pavilion 15-eh1xxx (mainboard 88D0)", ALC287_FIXUP_HP_GPIO_LED),
10733 SND_PCI_QUIRK(0x103c, 0x88dd, "HP Pavilion 15z-ec200", ALC285_FIXUP_HP_MUTE_LED),
10736 SND_PCI_QUIRK(0x103c, 0x8919, "HP Pavilion Aero Laptop 13-be0xxx", ALC287_FIXUP_HP_GPIO_LED),
10746 SND_PCI_QUIRK(0x103c, 0x898a, "HP Pavilion 15-eg100", ALC287_FIXUP_HP_GPIO_LED),
10764 SND_PCI_QUIRK(0x103c, 0x8a0f, "HP Pavilion 14-ec1xxx", ALC287_FIXUP_HP_GPIO_LED),
10765 SND_PCI_QUIRK(0x103c, 0x8a20, "HP Laptop 15s-fq5xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10766 SND_PCI_QUIRK(0x103c, 0x8a25, "HP Victus 16-d1xxx (MB 8A25)", ALC245_FIXUP_HP_MUTE_LED_COEFBIT),
10776 SND_PCI_QUIRK(0x103c, 0x8a4f, "HP Victus 15-fa0xxx (MB 8A4F)", ALC245_FIXUP_HP_MUTE_LED_COEFBIT),
10822 SND_PCI_QUIRK(0x103c, 0x8bbe, "HP Victus 16-r0xxx (MB 8BBE)", ALC245_FIXUP_HP_MUTE_LED_COEFBIT),
10823 SND_PCI_QUIRK(0x103c, 0x8bc8, "HP Victus 15-fa1xxx", ALC245_FIXUP_HP_MUTE_LED_COEFBIT),
10824 SND_PCI_QUIRK(0x103c, 0x8bcd, "HP Omen 16-xd0xxx", ALC245_FIXUP_HP_MUTE_LED_V1_COEFBIT),
10838 …SND_PCI_QUIRK(0x103c, 0x8c15, "HP Spectre x360 2-in-1 Laptop 14-eu0xxx", ALC245_FIXUP_HP_SPECTRE_X…
10839 …SND_PCI_QUIRK(0x103c, 0x8c16, "HP Spectre x360 2-in-1 Laptop 16-aa0xxx", ALC245_FIXUP_HP_SPECTRE_X…
10841 SND_PCI_QUIRK(0x103c, 0x8c21, "HP Pavilion Plus Laptop 14-ey0XXX", ALC245_FIXUP_HP_X360_MUTE_LEDS),
10842 SND_PCI_QUIRK(0x103c, 0x8c30, "HP Victus 15-fb1xxx", ALC245_FIXUP_HP_MUTE_LED_COEFBIT),
10846 …SND_PCI_QUIRK(0x103c, 0x8c49, "HP Elite x360 830 2-in-1 G11", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_L…
10853 SND_PCI_QUIRK(0x103c, 0x8c53, "HP Elite x360 1040 2-in-1 G11", ALC285_FIXUP_HP_GPIO_LED),
10877 SND_PCI_QUIRK(0x103c, 0x8c9c, "HP Victus 16-s1xxx (MB 8C9C)", ALC245_FIXUP_HP_MUTE_LED_COEFBIT),
10883 SND_PCI_QUIRK(0x103c, 0x8cbd, "HP Pavilion Aero Laptop 13-bg0xxx", ALC245_FIXUP_HP_X360_MUTE_LEDS),
10890 SND_PCI_QUIRK(0x103c, 0x8d07, "HP Victus 15-fb2xxx (MB 8D07)", ALC245_FIXUP_HP_MUTE_LED_COEFBIT),
11111 SND_PCI_QUIRK(0x10ec, 0x11bc, "VAIO VJFE-IL", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
11118 SND_PCI_QUIRK(0x10f7, 0x8338, "Panasonic CF-SZ6", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
11120 SND_PCI_QUIRK(0x144d, 0xc169, "Samsung Notebook 9 Pen (NP930SBE-K01US)", ALC298_FIXUP_SAMSUNG_AMP),
11121 SND_PCI_QUIRK(0x144d, 0xc176, "Samsung Notebook 9 Pro (NP930MBE-K04US)", ALC298_FIXUP_SAMSUNG_AMP),
11122 …SND_PCI_QUIRK(0x144d, 0xc189, "Samsung Galaxy Flex Book (NT950QCG-X716)", ALC298_FIXUP_SAMSUNG_AMP…
11123 …SND_PCI_QUIRK(0x144d, 0xc18a, "Samsung Galaxy Book Ion (NP930XCJ-K01US)", ALC298_FIXUP_SAMSUNG_AMP…
11124 …SND_PCI_QUIRK(0x144d, 0xc1a3, "Samsung Galaxy Book Pro (NP935XDB-KC1SE)", ALC298_FIXUP_SAMSUNG_AMP…
11128 SND_PCI_QUIRK(0x144d, 0xc812, "Samsung Notebook Pen S (NT950SBE-X58)", ALC298_FIXUP_SAMSUNG_AMP),
11129 …SND_PCI_QUIRK(0x144d, 0xc830, "Samsung Galaxy Book Ion (NT950XCJ-X716A)", ALC298_FIXUP_SAMSUNG_AMP…
11139 SND_PCI_QUIRK(0x1458, 0xfa53, "Gigabyte BXBT-2807", ALC283_FIXUP_HEADSET_MIC),
11140 SND_PCI_QUIRK(0x1462, 0xb120, "MSI Cubi MS-B120", ALC283_FIXUP_HEADSET_MIC),
11141 SND_PCI_QUIRK(0x1462, 0xb171, "Cubi N 8GL (MS-B171)", ALC283_FIXUP_HEADSET_MIC),
11143 SND_PCI_QUIRK(0x152d, 0x1262, "Huawei NBLB-WAX9N", ALC2XX_FIXUP_HEADSET_MIC),
11188 SND_PCI_QUIRK(0x1558, 0x70f6, "Clevo NH77DPQ-Y", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
11198 …SND_PCI_QUIRK(0x1558, 0x8550, "Clevo NH[57][0-9][ER][ACDH]Q", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENC…
11199 …SND_PCI_QUIRK(0x1558, 0x8551, "Clevo NH[57][0-9][ER][ACDH]Q", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENC…
11200 SND_PCI_QUIRK(0x1558, 0x8560, "Clevo NH[57][0-9][ER][ACDH]Q", ALC269_FIXUP_HEADSET_MIC),
11201 SND_PCI_QUIRK(0x1558, 0x8561, "Clevo NH[57][0-9][ER][ACDH]Q", ALC269_FIXUP_HEADSET_MIC),
11202 SND_PCI_QUIRK(0x1558, 0x8562, "Clevo NH[57][0-9]RZ[Q]", ALC269_FIXUP_DMIC),
11209 SND_PCI_QUIRK(0x1558, 0x8a20, "Clevo NH55DCQ-Y", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
11210 SND_PCI_QUIRK(0x1558, 0x8a51, "Clevo NH70RCQ-Y", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
11211 SND_PCI_QUIRK(0x1558, 0x8d50, "Clevo NH55RCQ-M", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
11257 SND_PCI_QUIRK(0x17aa, 0x2234, "Thinkpad ICE-1", ALC287_FIXUP_TAS2781_I2C),
11302 HDA_CODEC_QUIRK(0x17aa, 0x3820, "IdeaPad 330-17IKB 81DM", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
11324 SND_PCI_QUIRK(0x17aa, 0x387d, "Yoga S780-16 pro Quad AAC", ALC287_FIXUP_TAS2781_I2C),
11325 SND_PCI_QUIRK(0x17aa, 0x387e, "Yoga S780-16 pro Quad YC", ALC287_FIXUP_TAS2781_I2C),
11326 SND_PCI_QUIRK(0x17aa, 0x387f, "Yoga S780-16 pro dual LX", ALC287_FIXUP_TAS2781_I2C),
11327 SND_PCI_QUIRK(0x17aa, 0x3880, "Yoga S780-16 pro dual YC", ALC287_FIXUP_TAS2781_I2C),
11342 SND_PCI_QUIRK(0x17aa, 0x38b8, "Yoga S780-14.5 proX AMD YC Dual", ALC287_FIXUP_TAS2781_I2C),
11343 SND_PCI_QUIRK(0x17aa, 0x38b9, "Yoga S780-14.5 proX AMD LX Dual", ALC287_FIXUP_TAS2781_I2C),
11344 SND_PCI_QUIRK(0x17aa, 0x38ba, "Yoga S780-14.5 Air AMD quad YC", ALC287_FIXUP_TAS2781_I2C),
11345 SND_PCI_QUIRK(0x17aa, 0x38bb, "Yoga S780-14.5 Air AMD quad AAC", ALC287_FIXUP_TAS2781_I2C),
11346 SND_PCI_QUIRK(0x17aa, 0x38be, "Yoga S980-14.5 proX YC Dual", ALC287_FIXUP_TAS2781_I2C),
11347 SND_PCI_QUIRK(0x17aa, 0x38bf, "Yoga S980-14.5 proX LX Dual", ALC287_FIXUP_TAS2781_I2C),
11354 SND_PCI_QUIRK(0x17aa, 0x38d3, "Yoga S990-16 Pro IMH YC Dual", ALC287_FIXUP_TAS2781_I2C),
11355 SND_PCI_QUIRK(0x17aa, 0x38d4, "Yoga S990-16 Pro IMH VECO Dual", ALC287_FIXUP_TAS2781_I2C),
11356 SND_PCI_QUIRK(0x17aa, 0x38d5, "Yoga S990-16 Pro IMH YC Quad", ALC287_FIXUP_TAS2781_I2C),
11357 SND_PCI_QUIRK(0x17aa, 0x38d6, "Yoga S990-16 Pro IMH VECO Quad", ALC287_FIXUP_TAS2781_I2C),
11366 SND_PCI_QUIRK(0x17aa, 0x3902, "Lenovo E50-80", ALC269_FIXUP_DMIC_THINKPAD_ACPI),
11369 SND_PCI_QUIRK(0x17aa, 0x391f, "Yoga S990-16 pro Quad YC Quad", ALC287_FIXUP_TAS2781_I2C),
11370 SND_PCI_QUIRK(0x17aa, 0x3920, "Yoga S990-16 pro Quad VECO Quad", ALC287_FIXUP_TAS2781_I2C),
11372 SND_PCI_QUIRK(0x17aa, 0x3978, "Lenovo B50-70", ALC269_FIXUP_DMIC_THINKPAD_ACPI),
11402 SND_PCI_QUIRK(0x19e5, 0x3204, "Huawei MACH-WX9", ALC256_FIXUP_HUAWEI_MACH_WX9_PINS),
11403 SND_PCI_QUIRK(0x19e5, 0x320f, "Huawei WRT-WX9 ", ALC256_FIXUP_ASUS_MIC_NO_PRESENCE),
11404 SND_PCI_QUIRK(0x19e5, 0x3212, "Huawei KLV-WX9 ", ALC256_FIXUP_ACER_HEADSET_MIC),
11408 …b7d, 0xa831, "Ordissimo EVE2 ", ALC269VB_FIXUP_ORDISSIMO_EVE2), /* Also known as Malata PC-B1303 */
11412 SND_PCI_QUIRK(0x1c6c, 0x1251, "Positivo N14KP6-TG", ALC288_FIXUP_DELL1_MIC_NO_PRESENCE),
11432 SND_PCI_QUIRK(0x2782, 0x0214, "VAIO VJFE-CL", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
11439 SND_PCI_QUIRK(0x2782, 0x1707, "Vaio VJFE-ADL", ALC298_FIXUP_SPK_VOLUME),
11511 {.id = ALC269_FIXUP_AMIC, .name = "laptop-amic"},
11512 {.id = ALC269_FIXUP_DMIC, .name = "laptop-dmic"},
11513 {.id = ALC269_FIXUP_STEREO_DMIC, .name = "alc269-dmic"},
11514 {.id = ALC271_FIXUP_DMIC, .name = "alc271-dmic"},
11515 {.id = ALC269_FIXUP_INV_DMIC, .name = "inv-dmic"},
11516 {.id = ALC269_FIXUP_HEADSET_MIC, .name = "headset-mic"},
11517 {.id = ALC269_FIXUP_HEADSET_MODE, .name = "headset-mode"},
11518 {.id = ALC269_FIXUP_HEADSET_MODE_NO_HP_MIC, .name = "headset-mode-no-hp-mic"},
11519 {.id = ALC269_FIXUP_LENOVO_DOCK, .name = "lenovo-dock"},
11520 {.id = ALC269_FIXUP_LENOVO_DOCK_LIMIT_BOOST, .name = "lenovo-dock-limit-boost"},
11521 {.id = ALC269_FIXUP_HP_GPIO_LED, .name = "hp-gpio-led"},
11522 {.id = ALC269_FIXUP_HP_DOCK_GPIO_MIC1_LED, .name = "hp-dock-gpio-mic1-led"},
11523 {.id = ALC269_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "dell-headset-multi"},
11524 {.id = ALC269_FIXUP_DELL2_MIC_NO_PRESENCE, .name = "dell-headset-dock"},
11525 {.id = ALC269_FIXUP_DELL3_MIC_NO_PRESENCE, .name = "dell-headset3"},
11526 {.id = ALC269_FIXUP_DELL4_MIC_NO_PRESENCE, .name = "dell-headset4"},
11527 {.id = ALC269_FIXUP_DELL4_MIC_NO_PRESENCE_QUIET, .name = "dell-headset4-quiet"},
11528 {.id = ALC283_FIXUP_CHROME_BOOK, .name = "alc283-dac-wcaps"},
11529 {.id = ALC283_FIXUP_SENSE_COMBO_JACK, .name = "alc283-sense-combo"},
11530 {.id = ALC292_FIXUP_TPT440_DOCK, .name = "tpt440-dock"},
11533 {.id = ALC298_FIXUP_TPT470_DOCK_FIX, .name = "tpt470-dock-fix"},
11534 {.id = ALC298_FIXUP_TPT470_DOCK, .name = "tpt470-dock"},
11535 {.id = ALC233_FIXUP_LENOVO_MULTI_CODECS, .name = "dual-codecs"},
11536 {.id = ALC700_FIXUP_INTEL_REFERENCE, .name = "alc700-ref"},
11538 {.id = ALC269_FIXUP_DELL_M101Z, .name = "dell-m101z"},
11539 {.id = ALC269_FIXUP_ASUS_G73JW, .name = "asus-g73jw"},
11540 {.id = ALC269_FIXUP_LENOVO_EAPD, .name = "lenovo-eapd"},
11541 {.id = ALC275_FIXUP_SONY_HWEQ, .name = "sony-hweq"},
11544 {.id = ALC269_FIXUP_LIFEBOOK_EXTMIC, .name = "lifebook-extmic"},
11545 {.id = ALC269_FIXUP_LIFEBOOK_HP_PIN, .name = "lifebook-hp-pin"},
11546 {.id = ALC255_FIXUP_LIFEBOOK_U7x7_HEADSET_MIC, .name = "lifebook-u7x7"},
11547 {.id = ALC269VB_FIXUP_AMIC, .name = "alc269vb-amic"},
11548 {.id = ALC269VB_FIXUP_DMIC, .name = "alc269vb-dmic"},
11549 {.id = ALC269_FIXUP_HP_MUTE_LED_MIC1, .name = "hp-mute-led-mic1"},
11550 {.id = ALC269_FIXUP_HP_MUTE_LED_MIC2, .name = "hp-mute-led-mic2"},
11551 {.id = ALC269_FIXUP_HP_MUTE_LED_MIC3, .name = "hp-mute-led-mic3"},
11552 {.id = ALC269_FIXUP_HP_GPIO_MIC1_LED, .name = "hp-gpio-mic1"},
11553 {.id = ALC269_FIXUP_HP_LINE1_MIC1_LED, .name = "hp-line1-mic1"},
11555 {.id = ALC286_FIXUP_SONY_MIC_NO_PRESENCE, .name = "sony-nomic"},
11556 {.id = ALC269_FIXUP_ASPIRE_HEADSET_MIC, .name = "aspire-headset-mic"},
11557 {.id = ALC269_FIXUP_ASUS_X101, .name = "asus-x101"},
11558 {.id = ALC271_FIXUP_HP_GATE_MIC_JACK, .name = "acer-ao7xx"},
11559 {.id = ALC271_FIXUP_HP_GATE_MIC_JACK_E1_572, .name = "acer-aspire-e1"},
11560 {.id = ALC269_FIXUP_ACER_AC700, .name = "acer-ac700"},
11561 {.id = ALC269_FIXUP_LIMIT_INT_MIC_BOOST, .name = "limit-mic-boost"},
11562 {.id = ALC269VB_FIXUP_ASUS_ZENBOOK, .name = "asus-zenbook"},
11563 {.id = ALC269VB_FIXUP_ASUS_ZENBOOK_UX31A, .name = "asus-zenbook-ux31a"},
11565 {.id = ALC282_FIXUP_ASUS_TX300, .name = "asus-tx300"},
11566 {.id = ALC283_FIXUP_INT_MIC, .name = "alc283-int-mic"},
11567 {.id = ALC290_FIXUP_MONO_SPEAKERS_HSJACK, .name = "mono-speakers"},
11568 {.id = ALC290_FIXUP_SUBWOOFER_HSJACK, .name = "alc290-subwoofer"},
11570 {.id = ALC269_FIXUP_LENOVO_XPAD_ACPI, .name = "lenovo-xpad-led"},
11571 {.id = ALC269_FIXUP_DMIC_THINKPAD_ACPI, .name = "dmic-thinkpad"},
11572 {.id = ALC255_FIXUP_ACER_MIC_NO_PRESENCE, .name = "alc255-acer"},
11573 {.id = ALC255_FIXUP_ASUS_MIC_NO_PRESENCE, .name = "alc255-asus"},
11574 {.id = ALC255_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc255-dell1"},
11575 {.id = ALC255_FIXUP_DELL2_MIC_NO_PRESENCE, .name = "alc255-dell2"},
11576 {.id = ALC293_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc293-dell1"},
11577 {.id = ALC283_FIXUP_HEADSET_MIC, .name = "alc283-headset"},
11578 {.id = ALC255_FIXUP_MIC_MUTE_LED, .name = "alc255-dell-mute"},
11579 {.id = ALC282_FIXUP_ASPIRE_V5_PINS, .name = "aspire-v5"},
11580 {.id = ALC269VB_FIXUP_ASPIRE_E1_COEF, .name = "aspire-e1-coef"},
11581 {.id = ALC280_FIXUP_HP_GPIO4, .name = "hp-gpio4"},
11582 {.id = ALC286_FIXUP_HP_GPIO_LED, .name = "hp-gpio-led"},
11583 {.id = ALC280_FIXUP_HP_GPIO2_MIC_HOTKEY, .name = "hp-gpio2-hotkey"},
11584 {.id = ALC280_FIXUP_HP_DOCK_PINS, .name = "hp-dock-pins"},
11585 {.id = ALC269_FIXUP_HP_DOCK_GPIO_MIC1_LED, .name = "hp-dock-gpio-mic"},
11586 {.id = ALC280_FIXUP_HP_9480M, .name = "hp-9480m"},
11587 {.id = ALC288_FIXUP_DELL_HEADSET_MODE, .name = "alc288-dell-headset"},
11588 {.id = ALC288_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc288-dell1"},
11589 {.id = ALC288_FIXUP_DELL_XPS_13, .name = "alc288-dell-xps13"},
11590 {.id = ALC292_FIXUP_DELL_E7X, .name = "dell-e7x"},
11591 {.id = ALC293_FIXUP_DISABLE_AAMIX_MULTIJACK, .name = "alc293-dell"},
11592 {.id = ALC298_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc298-dell1"},
11593 {.id = ALC298_FIXUP_DELL_AIO_MIC_NO_PRESENCE, .name = "alc298-dell-aio"},
11594 {.id = ALC275_FIXUP_DELL_XPS, .name = "alc275-dell-xps"},
11595 {.id = ALC293_FIXUP_LENOVO_SPK_NOISE, .name = "lenovo-spk-noise"},
11596 {.id = ALC233_FIXUP_LENOVO_LINE2_MIC_HOTKEY, .name = "lenovo-hotkey"},
11597 {.id = ALC255_FIXUP_DELL_SPK_NOISE, .name = "dell-spk-noise"},
11598 {.id = ALC225_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc225-dell1"},
11599 {.id = ALC295_FIXUP_DISABLE_DAC3, .name = "alc295-disable-dac3"},
11600 {.id = ALC285_FIXUP_SPEAKER2_TO_DAC1, .name = "alc285-speaker2-to-dac1"},
11601 {.id = ALC280_FIXUP_HP_HEADSET_MIC, .name = "alc280-hp-headset"},
11602 {.id = ALC221_FIXUP_HP_FRONT_MIC, .name = "alc221-hp-mic"},
11603 {.id = ALC298_FIXUP_SPK_VOLUME, .name = "alc298-spk-volume"},
11604 {.id = ALC256_FIXUP_DELL_INSPIRON_7559_SUBWOOFER, .name = "dell-inspiron-7559"},
11605 {.id = ALC269_FIXUP_ATIV_BOOK_8, .name = "ativ-book"},
11606 {.id = ALC221_FIXUP_HP_MIC_NO_PRESENCE, .name = "alc221-hp-mic"},
11607 {.id = ALC256_FIXUP_ASUS_HEADSET_MODE, .name = "alc256-asus-headset"},
11608 {.id = ALC256_FIXUP_ASUS_MIC, .name = "alc256-asus-mic"},
11609 {.id = ALC256_FIXUP_ASUS_AIO_GPIO2, .name = "alc256-asus-aio"},
11610 {.id = ALC233_FIXUP_ASUS_MIC_NO_PRESENCE, .name = "alc233-asus"},
11611 {.id = ALC233_FIXUP_EAPD_COEF_AND_MIC_NO_PRESENCE, .name = "alc233-eapd"},
11612 {.id = ALC294_FIXUP_LENOVO_MIC_LOCATION, .name = "alc294-lenovo-mic"},
11613 {.id = ALC225_FIXUP_DELL_WYSE_MIC_NO_PRESENCE, .name = "alc225-wyse"},
11614 {.id = ALC274_FIXUP_DELL_AIO_LINEOUT_VERB, .name = "alc274-dell-aio"},
11615 {.id = ALC255_FIXUP_DUMMY_LINEOUT_VERB, .name = "alc255-dummy-lineout"},
11616 {.id = ALC255_FIXUP_DELL_HEADSET_MIC, .name = "alc255-dell-headset"},
11617 {.id = ALC295_FIXUP_HP_X360, .name = "alc295-hp-x360"},
11618 {.id = ALC225_FIXUP_HEADSET_JACK, .name = "alc-headset-jack"},
11619 {.id = ALC295_FIXUP_CHROME_BOOK, .name = "alc-chrome-book"},
11620 {.id = ALC256_FIXUP_CHROME_BOOK, .name = "alc-2024y-chromebook"},
11621 {.id = ALC299_FIXUP_PREDATOR_SPK, .name = "predator-spk"},
11622 {.id = ALC298_FIXUP_HUAWEI_MBX_STEREO, .name = "huawei-mbx-stereo"},
11623 {.id = ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE, .name = "alc256-medion-headset"},
11624 {.id = ALC298_FIXUP_SAMSUNG_AMP, .name = "alc298-samsung-amp"},
11625 {.id = ALC298_FIXUP_SAMSUNG_AMP_V2_2_AMPS, .name = "alc298-samsung-amp-v2-2-amps"},
11626 {.id = ALC298_FIXUP_SAMSUNG_AMP_V2_4_AMPS, .name = "alc298-samsung-amp-v2-4-amps"},
11627 {.id = ALC256_FIXUP_SAMSUNG_HEADPHONE_VERY_QUIET, .name = "alc256-samsung-headphone"},
11628 {.id = ALC255_FIXUP_XIAOMI_HEADSET_MIC, .name = "alc255-xiaomi-headset"},
11629 {.id = ALC274_FIXUP_HP_MIC, .name = "alc274-hp-mic-detect"},
11630 {.id = ALC245_FIXUP_HP_X360_AMP, .name = "alc245-hp-x360-amp"},
11631 {.id = ALC295_FIXUP_HP_OMEN, .name = "alc295-hp-omen"},
11632 {.id = ALC285_FIXUP_HP_SPECTRE_X360, .name = "alc285-hp-spectre-x360"},
11633 {.id = ALC285_FIXUP_HP_SPECTRE_X360_EB1, .name = "alc285-hp-spectre-x360-eb1"},
11634 {.id = ALC285_FIXUP_HP_SPECTRE_X360_DF1, .name = "alc285-hp-spectre-x360-df1"},
11635 {.id = ALC285_FIXUP_HP_ENVY_X360, .name = "alc285-hp-envy-x360"},
11636 {.id = ALC287_FIXUP_IDEAPAD_BASS_SPK_AMP, .name = "alc287-ideapad-bass-spk-amp"},
11637 {.id = ALC287_FIXUP_YOGA9_14IAP7_BASS_SPK_PIN, .name = "alc287-yoga9-bass-spk-pin"},
11638 {.id = ALC623_FIXUP_LENOVO_THINKSTATION_P340, .name = "alc623-lenovo-thinkstation-p340"},
11639 {.id = ALC255_FIXUP_ACER_HEADPHONE_AND_MIC, .name = "alc255-acer-headphone-and-mic"},
11640 {.id = ALC285_FIXUP_HP_GPIO_AMP_INIT, .name = "alc285-hp-amp-init"},
11641 {.id = ALC236_FIXUP_LENOVO_INV_DMIC, .name = "alc236-fixup-lenovo-inv-mic"},
11642 {.id = ALC2XX_FIXUP_HEADSET_MIC, .name = "alc2xx-fixup-headset-mic"},
12106 struct alc_spec *spec = codec->spec; in alc269_fill_coef()
12109 if (spec->codec_variant != ALC269_TYPE_ALC269VB) in alc269_fill_coef()
12129 if (val != -1 && (val & 0x0c00) >> 10 != 0x1) { in alc269_fill_coef()
12134 if (val != -1 && (val & 0x01c0) >> 6 != 0x4) { in alc269_fill_coef()
12155 spec = codec->spec; in patch_alc269()
12156 spec->gen.shared_mic_vref_pin = 0x18; in patch_alc269()
12157 codec->power_save_node = 0; in patch_alc269()
12158 spec->en_3kpull_low = true; in patch_alc269()
12160 codec->patch_ops.suspend = alc269_suspend; in patch_alc269()
12161 codec->patch_ops.resume = alc269_resume; in patch_alc269()
12162 spec->shutup = alc_default_shutup; in patch_alc269()
12163 spec->init_hook = alc_default_init; in patch_alc269()
12165 switch (codec->core.vendor_id) { in patch_alc269()
12167 spec->codec_variant = ALC269_TYPE_ALC269VA; in patch_alc269()
12170 if (codec->bus->pci && in patch_alc269()
12171 codec->bus->pci->subsystem_vendor == 0x1025 && in patch_alc269()
12172 spec->cdefine.platform_type == 1) in patch_alc269()
12174 spec->codec_variant = ALC269_TYPE_ALC269VB; in patch_alc269()
12177 if (codec->bus->pci && in patch_alc269()
12178 codec->bus->pci->subsystem_vendor == 0x17aa && in patch_alc269()
12179 codec->bus->pci->subsystem_device == 0x21f3) in patch_alc269()
12181 spec->codec_variant = ALC269_TYPE_ALC269VC; in patch_alc269()
12184 spec->codec_variant = ALC269_TYPE_ALC269VD; in patch_alc269()
12191 spec->shutup = alc269_shutup; in patch_alc269()
12192 spec->init_hook = alc269_fill_coef; in patch_alc269()
12198 spec->codec_variant = ALC269_TYPE_ALC280; in patch_alc269()
12201 spec->codec_variant = ALC269_TYPE_ALC282; in patch_alc269()
12202 spec->shutup = alc282_shutup; in patch_alc269()
12203 spec->init_hook = alc282_init; in patch_alc269()
12207 spec->codec_variant = ALC269_TYPE_ALC283; in patch_alc269()
12208 spec->shutup = alc283_shutup; in patch_alc269()
12209 spec->init_hook = alc283_init; in patch_alc269()
12213 spec->codec_variant = ALC269_TYPE_ALC284; in patch_alc269()
12216 spec->codec_variant = ALC269_TYPE_ALC293; in patch_alc269()
12220 spec->codec_variant = ALC269_TYPE_ALC286; in patch_alc269()
12223 spec->codec_variant = ALC269_TYPE_ALC298; in patch_alc269()
12227 spec->codec_variant = ALC269_TYPE_ALC255; in patch_alc269()
12228 spec->shutup = alc256_shutup; in patch_alc269()
12229 spec->init_hook = alc256_init; in patch_alc269()
12235 spec->codec_variant = ALC269_TYPE_ALC256; in patch_alc269()
12236 spec->shutup = alc256_shutup; in patch_alc269()
12237 spec->init_hook = alc256_init; in patch_alc269()
12238 spec->gen.mixer_nid = 0; /* ALC256 does not have any loopback mixer path */ in patch_alc269()
12239 if (codec->core.vendor_id == 0x10ec0236 && in patch_alc269()
12240 codec->bus->pci->vendor != PCI_VENDOR_ID_AMD) in patch_alc269()
12241 spec->en_3kpull_low = false; in patch_alc269()
12244 spec->codec_variant = ALC269_TYPE_ALC257; in patch_alc269()
12245 spec->shutup = alc256_shutup; in patch_alc269()
12246 spec->init_hook = alc256_init; in patch_alc269()
12247 spec->gen.mixer_nid = 0; in patch_alc269()
12248 spec->en_3kpull_low = false; in patch_alc269()
12255 spec->codec_variant = ALC269_TYPE_ALC245; in patch_alc269()
12257 spec->codec_variant = ALC269_TYPE_ALC215; in patch_alc269()
12258 spec->shutup = alc225_shutup; in patch_alc269()
12259 spec->init_hook = alc225_init; in patch_alc269()
12260 spec->gen.mixer_nid = 0; in patch_alc269()
12265 spec->codec_variant = ALC269_TYPE_ALC225; in patch_alc269()
12266 spec->shutup = alc225_shutup; in patch_alc269()
12267 spec->init_hook = alc225_init; in patch_alc269()
12268 spec->gen.mixer_nid = 0; /* no loopback on ALC225, ALC295 and ALC299 */ in patch_alc269()
12271 spec->codec_variant = ALC269_TYPE_ALC287; in patch_alc269()
12272 spec->shutup = alc225_shutup; in patch_alc269()
12273 spec->init_hook = alc225_init; in patch_alc269()
12274 spec->gen.mixer_nid = 0; /* no loopback on ALC287 */ in patch_alc269()
12279 spec->codec_variant = ALC269_TYPE_ALC294; in patch_alc269()
12280 spec->gen.mixer_nid = 0; /* ALC2x4 does not have any loopback mixer path */ in patch_alc269()
12282 spec->init_hook = alc294_init; in patch_alc269()
12285 spec->codec_variant = ALC269_TYPE_ALC300; in patch_alc269()
12286 spec->gen.mixer_nid = 0; /* no loopback on ALC300 */ in patch_alc269()
12290 spec->codec_variant = ALC269_TYPE_ALC623; in patch_alc269()
12291 spec->shutup = alc222_shutup; in patch_alc269()
12292 spec->init_hook = alc222_init; in patch_alc269()
12298 spec->codec_variant = ALC269_TYPE_ALC700; in patch_alc269()
12299 spec->gen.mixer_nid = 0; /* ALC700 does not have any loopback mixer path */ in patch_alc269()
12301 spec->init_hook = alc294_init; in patch_alc269()
12307 spec->has_alc5505_dsp = 1; in patch_alc269()
12308 spec->init_hook = alc5505_dsp_init; in patch_alc269()
12319 if (codec->fixup_id == ALC282_FIXUP_ASUS_TX300 && in patch_alc269()
12320 codec->core.vendor_id == 0x10ec0294) { in patch_alc269()
12322 codec->fixup_id = HDA_FIXUP_ID_NOT_SET; in patch_alc269()
12341 spec->gen.beep_nid = 0x01; in patch_alc269()
12348 if (!spec->gen.no_analog && spec->gen.beep_nid && spec->gen.mixer_nid) { in patch_alc269()
12349 err = set_beep_amp(spec, spec->gen.mixer_nid, 0x04, HDA_INPUT); in patch_alc269()
12387 struct alc_spec *spec = codec->spec; in alc861_fixup_asus_amp_vref_0f()
12397 spec->gen.keep_vref_in_automute = 1; in alc861_fixup_asus_amp_vref_0f()
12400 /* suppress the jack-detection */
12405 codec->no_jack_detect = 1; in alc_fixup_no_jack_detect()
12465 spec = codec->spec; in patch_alc861()
12467 spec->gen.beep_nid = 0x23; in patch_alc861()
12469 spec->power_hook = alc_power_eapd; in patch_alc861()
12481 if (!spec->gen.no_analog) { in patch_alc861()
12497 * ALC861-VD support
12529 struct alc_spec *spec = codec->spec; in alc660vd_fixup_asus_gpio1()
12532 spec->gpio_mask |= 0x02; in alc660vd_fixup_asus_gpio1()
12549 SND_PCI_QUIRK(0x1043, 0x1339, "ASUS A7-K", ALC660VD_FIX_ASUS_GPIO1),
12550 SND_PCI_QUIRK(0x1179, 0xff31, "Toshiba L30-149", ALC861VD_FIX_DALLAS),
12565 spec = codec->spec; in patch_alc861vd()
12567 spec->gen.beep_nid = 0x23; in patch_alc861vd()
12569 spec->shutup = alc_eapd_shutup; in patch_alc861vd()
12581 if (!spec->gen.no_analog) { in patch_alc861vd()
12602 * 6-channel independent captures.
12604 * In addition, an independent DAC for the multi-playback (not used in this
12619 if (codec->core.vendor_id == 0x10ec0272 || codec->core.vendor_id == 0x10ec0663 || in alc662_parse_auto_config()
12620 codec->core.vendor_id == 0x10ec0665 || codec->core.vendor_id == 0x10ec0670 || in alc662_parse_auto_config()
12621 codec->core.vendor_id == 0x10ec0671) in alc662_parse_auto_config()
12655 struct alc_spec *spec = codec->spec; in alc_fixup_bass_chmap()
12656 spec->gen.pcm_rec[0]->stream[0].chmap = asus_pcm_2_1_chmaps; in alc_fixup_bass_chmap()
12665 struct alc_spec *spec = codec->spec; in gpio_led_power_filter()
12666 if (nid == codec->core.afg && power_state == AC_PWRST_D3 && spec->gpio_data) in gpio_led_power_filter()
12674 struct alc_spec *spec = codec->spec; in alc662_fixup_led_gpio1()
12678 spec->mute_led_polarity = 1; in alc662_fixup_led_gpio1()
12679 codec->power_filter = gpio_led_power_filter; in alc662_fixup_led_gpio1()
12686 struct alc_spec *spec = codec->spec; in alc662_usi_automute_hook()
12691 vref = spec->gen.hp_jack_present ? PIN_VREF80 : 0; in alc662_usi_automute_hook()
12700 struct alc_spec *spec = codec->spec; in alc662_fixup_usi_headset_mic()
12702 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc662_fixup_usi_headset_mic()
12703 spec->gen.hp_automute_hook = alc662_usi_automute_hook; in alc662_fixup_usi_headset_mic()
12713 * 0x15 - front left/front right in alc662_aspire_ethos_mute_speakers()
12714 * 0x18 - front center/ LFE in alc662_aspire_ethos_mute_speakers()
12751 struct alc_spec *spec = codec->spec; in alc671_fixup_hp_headset_mic2()
12754 { 0x19, 0x02a11040 }, /* use as headset mic, with its own jack detect */ in alc671_fixup_hp_headset_mic2()
12761 spec->gen.mixer_nid = 0; in alc671_fixup_hp_headset_mic2()
12762 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc671_fixup_hp_headset_mic2()
12774 struct alc_spec *spec = codec->spec; in alc897_hp_automute_hook()
12778 vref = spec->gen.hp_jack_present ? (PIN_HP | AC_PINCTL_VREF_100) : PIN_HP; in alc897_hp_automute_hook()
12785 struct alc_spec *spec = codec->spec; in alc897_fixup_lenovo_headset_mic()
12787 spec->gen.hp_automute_hook = alc897_hp_automute_hook; in alc897_fixup_lenovo_headset_mic()
12788 spec->no_shutup_pins = 1; in alc897_fixup_lenovo_headset_mic()
12798 struct alc_spec *spec = codec->spec; in alc897_fixup_lenovo_headset_mode()
12801 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc897_fixup_lenovo_headset_mode()
12802 spec->gen.hp_automute_hook = alc897_hp_automute_hook; in alc897_fixup_lenovo_headset_mode()
12928 {0x19, 0x90a7013f}, /* int-mic */
12964 { 0x19, 0x99a3092f }, /* int-mic */
12976 { 0x19, 0x99a3092f }, /* int-mic */
12989 { 0x19, 0x99a3094f }, /* int-mic */
13002 { 0x19, 0x99a3094f }, /* int-mic */
13016 { 0x19, 0x99a3094f }, /* int-mic */
13028 { 0x19, 0x99a3094f }, /* int-mic */
13041 { 0x19, 0x99a3094f }, /* int-mic */
13053 { 0x12, 0x99a30970 }, /* int-mic */
13099 { 0x19, 0x03a1113c }, /* use as headset mic, without its own jack detect */
13113 { 0x19, 0x03a1913d }, /* use as headphone mic, without its own jack detect */
13114 { 0x1b, 0x03a1113c }, /* use as headset mic, without its own jack detect */
13166 { 0x19, 0x03a1913d }, /* use as headphone mic, without its own jack detect */
13168 { 0x1b, 0x03a1113c }, /* use as headset mic, without its own jack detect */
13198 { 0x19, 0x03a1913d }, /* use as headphone mic, without its own jack detect */
13199 { 0x1b, 0x03a1113c }, /* use as headset mic, without its own jack detect */
13227 { 0x19, 0x02a1913c }, /* use as headset mic, without its own jack detect */
13260 { 0x1a, 0x02a1113c }, /* use as headset mic, without its own jack detect */
13269 { 0x1a, 0x01a11140 }, /* use as headset mic, without its own jack detect */
13315 { 0x19, 0x01a1913c }, /* use as headset mic, without its own jack detect */
13326 { 0x1a, 0x01a11140 }, /* use as headset mic, without its own jack detect */
13342 { 0x19, 0x03a11050 }, /* use as headset mic */
13350 SND_PCI_QUIRK(0x1019, 0x9859, "JP-IK LEAP W502", ALC897_FIXUP_HEADSET_MIC_PIN3),
13359 SND_PCI_QUIRK(0x1025, 0x123c, "Acer Nitro N50-600", ALC662_FIXUP_ACER_NITRO_HEADSET_MODE),
13406 SND_PCI_QUIRK(0x17aa, 0x3742, "Lenovo TianYi510Pro-14IOB", ALC897_FIXUP_HEADSET_MIC_PIN2),
13414 SND_PCI_QUIRK(0x1c6c, 0x1239, "Compaq N14JP6-V2", ALC897_FIXUP_HP_HSMIC_VERB),
13480 {.id = ALC662_FIXUP_HP_RP5800, .name = "hp-rp5800"},
13481 {.id = ALC662_FIXUP_ASUS_MODE1, .name = "asus-mode1"},
13482 {.id = ALC662_FIXUP_ASUS_MODE2, .name = "asus-mode2"},
13483 {.id = ALC662_FIXUP_ASUS_MODE3, .name = "asus-mode3"},
13484 {.id = ALC662_FIXUP_ASUS_MODE4, .name = "asus-mode4"},
13485 {.id = ALC662_FIXUP_ASUS_MODE5, .name = "asus-mode5"},
13486 {.id = ALC662_FIXUP_ASUS_MODE6, .name = "asus-mode6"},
13487 {.id = ALC662_FIXUP_ASUS_MODE7, .name = "asus-mode7"},
13488 {.id = ALC662_FIXUP_ASUS_MODE8, .name = "asus-mode8"},
13489 {.id = ALC662_FIXUP_ZOTAC_Z68, .name = "zotac-z68"},
13490 {.id = ALC662_FIXUP_INV_DMIC, .name = "inv-dmic"},
13491 {.id = ALC662_FIXUP_DELL_MIC_NO_PRESENCE, .name = "alc662-headset-multi"},
13492 {.id = ALC668_FIXUP_DELL_MIC_NO_PRESENCE, .name = "dell-headset-multi"},
13493 {.id = ALC662_FIXUP_HEADSET_MODE, .name = "alc662-headset"},
13494 {.id = ALC668_FIXUP_HEADSET_MODE, .name = "alc668-headset"},
13498 {.id = ALC668_FIXUP_DELL_XPS13, .name = "dell-xps13"},
13499 {.id = ALC662_FIXUP_ASUS_Nx50, .name = "asus-nx50"},
13500 {.id = ALC668_FIXUP_ASUS_Nx51, .name = "asus-nx51"},
13501 {.id = ALC668_FIXUP_ASUS_G751, .name = "asus-g751"},
13502 {.id = ALC891_FIXUP_HEADSET_MODE, .name = "alc891-headset"},
13503 {.id = ALC891_FIXUP_DELL_MIC_NO_PRESENCE, .name = "alc891-headset-multi"},
13504 {.id = ALC662_FIXUP_ACER_VERITON, .name = "acer-veriton"},
13505 {.id = ALC892_FIXUP_ASROCK_MOBO, .name = "asrock-mobo"},
13506 {.id = ALC662_FIXUP_USI_HEADSET_MODE, .name = "usi-headset"},
13507 {.id = ALC662_FIXUP_LENOVO_MULTI_CODECS, .name = "dual-codecs"},
13508 {.id = ALC669_FIXUP_ACER_ASPIRE_ETHOS, .name = "aspire-ethos"},
13509 {.id = ALC897_FIXUP_UNIS_H3C_X500S, .name = "unis-h3c-x500s"},
13583 spec = codec->spec; in patch_alc662()
13585 spec->shutup = alc_eapd_shutup; in patch_alc662()
13588 spec->parse_flags = HDA_PINCFG_NO_HP_FIXUP; in patch_alc662()
13592 switch (codec->core.vendor_id) { in patch_alc662()
13594 spec->init_hook = alc668_restore_default_value; in patch_alc662()
13608 spec->gen.beep_nid = 0x01; in patch_alc662()
13611 codec->bus->pci && codec->bus->pci->subsystem_vendor == 0x1025 && in patch_alc662()
13612 spec->cdefine.platform_type == 1) { in patch_alc662()
13623 if (!spec->gen.no_analog && spec->gen.beep_nid) { in patch_alc662()
13624 switch (codec->core.vendor_id) { in patch_alc662()
13666 /* ALC680 has no aa-loopback mixer */ in patch_alc680()
13728 HDA_CODEC_ENTRY(0x10ec0660, "ALC660-VD", patch_alc861vd),
13730 HDA_CODEC_ENTRY(0x10ec0862, "ALC861-VD", patch_alc861vd),
13769 MODULE_DESCRIPTION("Realtek HD-audio codec");