Lines Matching +full:aac +full:- +full:mode

1 // SPDX-License-Identifier: GPL-2.0-or-later
38 /* extra amp-initialization sequence types */
147 struct alc_spec *spec = codec->spec; in coef_mutex_lock()
150 mutex_lock(&spec->coef_mutex); in coef_mutex_lock()
155 struct alc_spec *spec = codec->spec; in coef_mutex_unlock()
157 mutex_unlock(&spec->coef_mutex); in coef_mutex_unlock()
209 if (val != -1) in __alc_update_coefex_idx()
229 struct alc_spec *spec = codec->spec; in alc_get_coef0()
231 if (!spec->coef0) in alc_get_coef0()
232 spec->coef0 = alc_read_coef_idx(codec, 0); in alc_get_coef0()
233 return spec->coef0; in alc_get_coef0()
246 #define WRITE_COEFEX(_nid, _idx, _val) UPDATE_COEFEX(_nid, _idx, -1, _val)
254 for (; fw->nid; fw++) { in alc_process_coef_fw()
255 if (fw->mask == (unsigned short)-1) in alc_process_coef_fw()
256 __alc_write_coefex_idx(codec, fw->nid, fw->idx, fw->val); in alc_process_coef_fw()
258 __alc_update_coefex_idx(codec, fw->nid, fw->idx, in alc_process_coef_fw()
259 fw->mask, fw->val); in alc_process_coef_fw()
271 struct alc_spec *spec = codec->spec; in alc_setup_gpio()
273 spec->gpio_mask |= mask; in alc_setup_gpio()
274 spec->gpio_dir |= mask; in alc_setup_gpio()
275 spec->gpio_data |= mask; in alc_setup_gpio()
280 struct alc_spec *spec = codec->spec; in alc_write_gpio_data()
283 spec->gpio_data); in alc_write_gpio_data()
289 struct alc_spec *spec = codec->spec; in alc_update_gpio_data()
290 unsigned int oldval = spec->gpio_data; in alc_update_gpio_data()
293 spec->gpio_data |= mask; in alc_update_gpio_data()
295 spec->gpio_data &= ~mask; in alc_update_gpio_data()
296 if (oldval != spec->gpio_data) in alc_update_gpio_data()
302 struct alc_spec *spec = codec->spec; in alc_write_gpio()
304 if (!spec->gpio_mask) in alc_write_gpio()
307 snd_hda_codec_write(codec, codec->core.afg, 0, in alc_write_gpio()
308 AC_VERB_SET_GPIO_MASK, spec->gpio_mask); in alc_write_gpio()
309 snd_hda_codec_write(codec, codec->core.afg, 0, in alc_write_gpio()
310 AC_VERB_SET_GPIO_DIRECTION, spec->gpio_dir); in alc_write_gpio()
311 if (spec->gpio_write_delay) in alc_write_gpio()
361 struct alc_spec *spec = codec->spec; in alc_fix_pll()
363 if (spec->pll_nid) in alc_fix_pll()
364 alc_update_coefex_idx(codec, spec->pll_nid, spec->pll_coef_idx, in alc_fix_pll()
365 1 << spec->pll_coef_bit, 0); in alc_fix_pll()
371 struct alc_spec *spec = codec->spec; in alc_fix_pll_init()
372 spec->pll_nid = nid; in alc_fix_pll_init()
373 spec->pll_coef_idx = coef_idx; in alc_fix_pll_init()
374 spec->pll_coef_bit = coef_bit; in alc_fix_pll_init()
378 /* update the master volume per volume-knob's unsol event */
392 val = snd_hda_codec_read(codec, jack->nid, 0, in alc_update_knob_master()
395 uctl->value.integer.value[0] = val; in alc_update_knob_master()
396 uctl->value.integer.value[1] = val; in alc_update_knob_master()
397 kctl->put(kctl, uctl); in alc_update_knob_master()
415 switch (codec->core.vendor_id) { in alc_fill_eapd_coef()
530 /* alc888-VA */ in alc888_coef_init()
532 /* alc888-VB */ in alc888_coef_init()
572 if (codec->bus->shutdown) in alc_headset_mic_no_shutup()
575 snd_array_for_each(&codec->init_pins, i, pin) { in alc_headset_mic_no_shutup()
577 if (pin->nid != mic_pin) in alc_headset_mic_no_shutup()
578 snd_hda_codec_read(codec, pin->nid, 0, in alc_headset_mic_no_shutup()
582 codec->pins_shutup = 1; in alc_headset_mic_no_shutup()
587 struct alc_spec *spec = codec->spec; in alc_shutup_pins()
589 switch (codec->core.vendor_id) { in alc_shutup_pins()
604 if (!spec->no_shutup_pins) in alc_shutup_pins()
611 * just turning off EAPD and a little pause for avoiding pop-noise
615 struct alc_spec *spec = codec->spec; in alc_eapd_shutup()
618 if (!spec->no_depop_delay) in alc_eapd_shutup()
630 switch (codec->core.vendor_id) { in alc_auto_init_amp()
651 if (spec->gen.autocfg.hp_pins[0]) in alc_get_hp_pin()
652 return spec->gen.autocfg.hp_pins[0]; in alc_get_hp_pin()
653 if (spec->gen.autocfg.line_out_type == AC_JACK_HP_OUT) in alc_get_hp_pin()
654 return spec->gen.autocfg.line_out_pins[0]; in alc_get_hp_pin()
662 /* Could be any non-zero and even value. When used as fixup, tells
670 struct alc_spec *spec = codec->spec; in alc_fixup_sku_ignore()
672 spec->cdefine.fixup = 1; in alc_fixup_sku_ignore()
673 spec->cdefine.sku_cfg = ALC_FIXUP_SKU_IGNORE; in alc_fixup_sku_ignore()
680 struct alc_spec *spec = codec->spec; in alc_fixup_no_depop_delay()
683 spec->no_depop_delay = 1; in alc_fixup_no_depop_delay()
684 codec->depop_delay = 0; in alc_fixup_no_depop_delay()
692 struct alc_spec *spec = codec->spec; in alc_auto_parse_customize_define()
694 spec->cdefine.enable_pcbeep = 1; /* assume always enabled */ in alc_auto_parse_customize_define()
696 if (spec->cdefine.fixup) { in alc_auto_parse_customize_define()
697 ass = spec->cdefine.sku_cfg; in alc_auto_parse_customize_define()
699 return -1; in alc_auto_parse_customize_define()
703 if (!codec->bus->pci) in alc_auto_parse_customize_define()
704 return -1; in alc_auto_parse_customize_define()
705 ass = codec->core.subsystem_id & 0xffff; in alc_auto_parse_customize_define()
706 if (ass != codec->bus->pci->subsystem_device && (ass & 1)) in alc_auto_parse_customize_define()
710 if (codec->core.vendor_id == 0x10ec0260) in alc_auto_parse_customize_define()
716 codec->core.chip_name, ass); in alc_auto_parse_customize_define()
717 return -1; in alc_auto_parse_customize_define()
727 return -1; in alc_auto_parse_customize_define()
729 spec->cdefine.port_connectivity = ass >> 30; in alc_auto_parse_customize_define()
730 spec->cdefine.enable_pcbeep = (ass & 0x100000) >> 20; in alc_auto_parse_customize_define()
731 spec->cdefine.check_sum = (ass >> 16) & 0xf; in alc_auto_parse_customize_define()
732 spec->cdefine.customization = ass >> 8; in alc_auto_parse_customize_define()
734 spec->cdefine.sku_cfg = ass; in alc_auto_parse_customize_define()
735 spec->cdefine.external_amp = (ass & 0x38) >> 3; in alc_auto_parse_customize_define()
736 spec->cdefine.platform_type = (ass & 0x4) >> 2; in alc_auto_parse_customize_define()
737 spec->cdefine.swap = (ass & 0x2) >> 1; in alc_auto_parse_customize_define()
738 spec->cdefine.override = ass & 0x1; in alc_auto_parse_customize_define()
741 nid, spec->cdefine.sku_cfg); in alc_auto_parse_customize_define()
743 spec->cdefine.port_connectivity); in alc_auto_parse_customize_define()
744 codec_dbg(codec, "SKU: enable_pcbeep=0x%x\n", spec->cdefine.enable_pcbeep); in alc_auto_parse_customize_define()
745 codec_dbg(codec, "SKU: check_sum=0x%08x\n", spec->cdefine.check_sum); in alc_auto_parse_customize_define()
746 codec_dbg(codec, "SKU: customization=0x%08x\n", spec->cdefine.customization); in alc_auto_parse_customize_define()
747 codec_dbg(codec, "SKU: external_amp=0x%x\n", spec->cdefine.external_amp); in alc_auto_parse_customize_define()
748 codec_dbg(codec, "SKU: platform_type=0x%x\n", spec->cdefine.platform_type); in alc_auto_parse_customize_define()
749 codec_dbg(codec, "SKU: swap=0x%x\n", spec->cdefine.swap); in alc_auto_parse_customize_define()
750 codec_dbg(codec, "SKU: override=0x%x\n", spec->cdefine.override); in alc_auto_parse_customize_define()
755 /* return the position of NID in the list, or -1 if not found */
762 return -1; in find_idx_in_nid_list()
770 /* check subsystem ID and set up device-specific initialization;
773 /* 32-bit subsystem ID for BIOS loading in HD Audio codec.
777 * port-A --> pin 39/41, port-E --> pin 14/15, port-D --> pin 35/36
783 struct alc_spec *spec = codec->spec; in alc_subsystem_id()
785 if (spec->cdefine.fixup) { in alc_subsystem_id()
786 ass = spec->cdefine.sku_cfg; in alc_subsystem_id()
792 ass = codec->core.subsystem_id & 0xffff; in alc_subsystem_id()
793 if (codec->bus->pci && in alc_subsystem_id()
794 ass != codec->bus->pci->subsystem_device && (ass & 1)) in alc_subsystem_id()
807 if (codec->core.vendor_id == 0x10ec0260) in alc_subsystem_id()
828 ass & 0xffff, codec->core.vendor_id); in alc_subsystem_id()
832 * 2 : 0 --> Desktop, 1 --> Laptop in alc_subsystem_id()
837 if (spec->init_amp == ALC_INIT_UNDEFINED) { in alc_subsystem_id()
850 spec->init_amp = ALC_INIT_DEFAULT; in alc_subsystem_id()
862 * 12~11: Headphone out -> 00: PortA, 01: PortE, 02: PortD, 03: Resvered in alc_subsystem_id()
864 * 15 : 1 --> enable the function "Mute internal speaker in alc_subsystem_id()
871 if (found_in_nid_list(nid, spec->gen.autocfg.line_out_pins, in alc_subsystem_id()
872 spec->gen.autocfg.line_outs)) in alc_subsystem_id()
874 spec->gen.autocfg.hp_pins[0] = nid; in alc_subsystem_id()
879 /* Check the validity of ALC subsystem-id
880 * ports contains an array of 4 pin NIDs for port-A, E, D and I */
884 struct alc_spec *spec = codec->spec; in alc_ssid_check()
885 if (spec->init_amp == ALC_INIT_UNDEFINED) { in alc_ssid_check()
887 "realtek: Enable default setup for auto mode as fallback\n"); in alc_ssid_check()
888 spec->init_amp = ALC_INIT_DEFAULT; in alc_ssid_check()
899 struct alc_spec *spec = codec->spec; in alc_fixup_inv_dmic()
901 spec->gen.inv_dmic_split = 1; in alc_fixup_inv_dmic()
928 ((codec)->core.dev.power.power_state.event == PM_EVENT_RESUME)
930 ((codec)->core.dev.power.power_state.event == PM_EVENT_RESTORE)
932 ((codec)->core.dev.power.power_state.event == PM_EVENT_FREEZE)
936 struct alc_spec *spec = codec->spec; in alc_init()
942 if (spec->init_hook) in alc_init()
943 spec->init_hook(codec); in alc_init()
945 spec->gen.skip_verbs = 1; /* applied in below */ in alc_init()
948 alc_auto_init_amp(codec, spec->init_amp); in alc_init()
961 struct alc_spec *spec = codec->spec; in alc_free()
964 hda_component_manager_free(&spec->comps, &comp_master_ops); in alc_free()
971 struct alc_spec *spec = codec->spec; in alc_shutup()
976 if (spec && spec->shutup) in alc_shutup()
977 spec->shutup(codec); in alc_shutup()
989 struct alc_spec *spec = codec->spec; in alc_suspend()
991 if (spec && spec->power_hook) in alc_suspend()
992 spec->power_hook(codec); in alc_suspend()
998 struct alc_spec *spec = codec->spec; in alc_resume()
1000 if (!spec->no_depop_delay) in alc_resume()
1002 codec->patch_ops.init(codec); in alc_resume()
1052 { 0x10ec0887, 0x00f0, 0x0030, "ALC887-VD" },
1053 { 0x10ec0888, 0x00f0, 0x0030, "ALC888-VD" },
1098 for (p = rename_tbl; p->vendor_id; p++) { in alc_codec_rename_from_preset()
1099 if (p->vendor_id != codec->core.vendor_id) in alc_codec_rename_from_preset()
1101 if ((alc_get_coef0(codec) & p->coef_mask) == p->coef_bits) in alc_codec_rename_from_preset()
1102 return alc_codec_rename(codec, p->name); in alc_codec_rename_from_preset()
1105 if (!codec->bus->pci) in alc_codec_rename_from_preset()
1107 for (q = rename_pci_tbl; q->codec_vendor_id; q++) { in alc_codec_rename_from_preset()
1108 if (q->codec_vendor_id != codec->core.vendor_id) in alc_codec_rename_from_preset()
1110 if (q->pci_subvendor != codec->bus->pci->subsystem_vendor) in alc_codec_rename_from_preset()
1112 if (!q->pci_subdevice || in alc_codec_rename_from_preset()
1113 q->pci_subdevice == codec->bus->pci->subsystem_device) in alc_codec_rename_from_preset()
1114 return alc_codec_rename(codec, q->name); in alc_codec_rename_from_preset()
1122 * Digital-beep handlers
1141 knew = snd_hda_gen_add_kctl(&spec->gen, NULL, in set_beep_amp()
1144 return -ENOMEM; in set_beep_amp()
1145 knew->private_value = beep_amp; in set_beep_amp()
1158 SND_PCI_QUIRK(0x1458, 0xa002, "GA-MA790X", 1),
1160 /* denylist -- no beep available */
1168 struct alc_spec *spec = codec->spec; in has_cdefine_beep()
1170 q = snd_pci_quirk_lookup(codec->bus->pci, beep_allow_list); in has_cdefine_beep()
1172 return q->value; in has_cdefine_beep()
1173 return spec->cdefine.enable_pcbeep; in has_cdefine_beep()
1188 struct alc_spec *spec = codec->spec; in alc_parse_auto_config()
1189 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in alc_parse_auto_config()
1193 spec->parse_flags); in alc_parse_auto_config()
1214 return -ENOMEM; in alc_alloc_spec()
1215 codec->spec = spec; in alc_alloc_spec()
1216 snd_hda_gen_spec_init(&spec->gen); in alc_alloc_spec()
1217 spec->gen.mixer_nid = mixer_nid; in alc_alloc_spec()
1218 spec->gen.own_eapd_ctl = 1; in alc_alloc_spec()
1219 codec->single_adc_amp = 1; in alc_alloc_spec()
1221 codec->spdif_status_reset = 1; in alc_alloc_spec()
1222 codec->forced_resume = 1; in alc_alloc_spec()
1223 codec->patch_ops = alc_patch_ops; in alc_alloc_spec()
1224 mutex_init(&spec->coef_mutex); in alc_alloc_spec()
1242 * ALC880 fix-ups
1272 /* enable the volume-knob widget support on NID 0x21 */
1313 { 0x1a, 0x0181344f }, /* line-in */
1331 /* change to EAPD mode */
1340 /* change to EAPD mode */
1361 { 0x19, 0x01a19950 }, /* mic-in */
1381 { 0x19, 0x01a19950 }, /* mic-in */
1421 { 0x18, 0x01a19950 }, /* mic-in */
1423 { 0x1a, 0x01813031 }, /* line-in */
1454 { 0x14, 0x01014010 }, /* line-out */
1458 { 0x18, 0x01a19c30 }, /* mic-in */
1460 { 0x1a, 0x01813031 }, /* line-in */
1461 { 0x1b, 0x02a19c40 }, /* front-mic */
1494 { 0x18, 0x01a19c30 }, /* mic-in */
1496 { 0x1a, 0x01813031 }, /* line-in */
1497 { 0x1b, 0x02a19c40 }, /* front-mic */
1530 { 0x18, 0x01a19c30 }, /* mic-in */
1531 { 0x19, 0x02a19c40 }, /* front-mic */
1532 { 0x1a, 0x01813031 }, /* line-in */
1596 * It's not quite sure whether BIOS sets the correct pin-config table
1621 SND_PCI_QUIRK(0x1695, 0x4012, "EPox EP-5LDA", ALC880_FIXUP_5ST_DIG),
1636 SND_PCI_QUIRK(0xa0a0, 0x0560, "AOpen i915GMm-HFS", ALC880_FIXUP_5ST_DIG),
1643 {.id = ALC880_FIXUP_3ST_DIG, .name = "3stack-digout"},
1645 {.id = ALC880_FIXUP_5ST_DIG, .name = "5stack-digout"},
1647 {.id = ALC880_FIXUP_6ST_DIG, .name = "6stack-digout"},
1648 {.id = ALC880_FIXUP_6ST_AUTOMUTE, .name = "6stack-automute"},
1665 spec = codec->spec; in patch_alc880()
1666 spec->gen.need_dac_fix = 1; in patch_alc880()
1667 spec->gen.beep_nid = 0x01; in patch_alc880()
1669 codec->patch_ops.unsol_event = alc880_unsol_event; in patch_alc880()
1682 if (!spec->gen.no_analog) { in patch_alc880()
1727 struct alc_spec *spec = codec->spec; in alc260_gpio1_automute()
1729 alc_update_gpio_data(codec, 0x01, spec->gen.hp_jack_present); in alc260_gpio1_automute()
1735 struct alc_spec *spec = codec->spec; in alc260_fixup_gpio1_toggle()
1740 spec->gen.automute_hook = alc260_gpio1_automute; in alc260_fixup_gpio1_toggle()
1741 spec->gen.detect_hp = 1; in alc260_fixup_gpio1_toggle()
1742 spec->gen.automute_speaker = 1; in alc260_fixup_gpio1_toggle()
1743 spec->gen.autocfg.hp_pins[0] = 0x0f; /* copy it for automute */ in alc260_fixup_gpio1_toggle()
1753 struct alc_spec *spec = codec->spec; in alc260_fixup_kn1()
1773 spec->init_amp = ALC_INIT_NONE; in alc260_fixup_kn1()
1781 struct alc_spec *spec = codec->spec; in alc260_fixup_fsc_s7020()
1783 spec->init_amp = ALC_INIT_NONE; in alc260_fixup_fsc_s7020()
1789 struct alc_spec *spec = codec->spec; in alc260_fixup_fsc_s7020_jwse()
1791 spec->gen.add_jack_modes = 1; in alc260_fixup_fsc_s7020_jwse()
1792 spec->gen.hp_mic = 1; in alc260_fixup_fsc_s7020_jwse()
1899 {.id = ALC260_FIXUP_FSC_S7020_JWSE, .name = "fujitsu-jwse"},
1914 spec = codec->spec; in patch_alc260()
1919 spec->gen.prefer_hp_amp = 1; in patch_alc260()
1920 spec->gen.beep_nid = 0x01; in patch_alc260()
1922 spec->shutup = alc_eapd_shutup; in patch_alc260()
1935 if (!spec->gen.no_analog) { in patch_alc260()
1957 * 6-channel independent captures.
1959 * In addition, an independent DAC for the multi-playback (not used in this
2023 struct alc_spec *spec = codec->spec; in alc885_fixup_macpro_gpio()
2025 spec->gpio_write_delay = true; in alc885_fixup_macpro_gpio()
2059 struct alc_spec *spec = codec->spec; in alc889_fixup_mbp_vref()
2071 spec->gen.keep_vref_in_automute = 1; in alc889_fixup_mbp_vref()
2079 struct alc_spec *spec = codec->spec; in alc889_fixup_mac_pins()
2088 spec->gen.keep_vref_in_automute = 1; in alc889_fixup_mac_pins()
2123 * all-in-one desktop PCs (for example VGC-LN51JGB) through DAC 0x05
2128 struct alc_spec *spec = codec->spec; in alc882_fixup_no_primary_hp()
2130 spec->gen.no_primary_hp = 1; in alc882_fixup_no_primary_hp()
2131 spec->gen.no_multi_io = 1; in alc882_fixup_no_primary_hp()
2138 /* For dual-codec configuration, we need to disable some features to avoid
2144 struct alc_spec *spec = codec->spec; in alc_fixup_dual_codecs()
2149 spec->gen.suppress_vmaster = 1; in alc_fixup_dual_codecs()
2150 /* auto-mute and auto-mic switch don't work with multiple codecs */ in alc_fixup_dual_codecs()
2151 spec->gen.suppress_auto_mute = 1; in alc_fixup_dual_codecs()
2152 spec->gen.suppress_auto_mic = 1; in alc_fixup_dual_codecs()
2154 spec->gen.mixer_nid = 0; in alc_fixup_dual_codecs()
2156 codec->force_pin_prefix = 1; in alc_fixup_dual_codecs()
2166 snd_ctl_rename(codec->card, kctl, newname); in rename_ctl()
2177 strcpy(codec->card->longname, "HDAudio-Gigabyte-ALC1220DualCodecs"); in alc1220_fixup_gb_dual_codecs()
2182 codec->addr == 0 ? in alc1220_fixup_gb_dual_codecs()
2183 "Rear-Panel Capture Volume" : in alc1220_fixup_gb_dual_codecs()
2184 "Front-Panel Capture Volume"); in alc1220_fixup_gb_dual_codecs()
2186 codec->addr == 0 ? in alc1220_fixup_gb_dual_codecs()
2187 "Rear-Panel Capture Switch" : in alc1220_fixup_gb_dual_codecs()
2188 "Front-Panel Capture Switch"); in alc1220_fixup_gb_dual_codecs()
2248 struct alc_spec *spec = codec->spec; in alc887_asus_hp_automute_hook()
2253 if (spec->gen.hp_jack_present) in alc887_asus_hp_automute_hook()
2263 struct alc_spec *spec = codec->spec; in alc887_fixup_asus_jack()
2267 spec->gen.hp_automute_hook = alc887_asus_hp_automute_hook; in alc887_fixup_asus_jack()
2340 /* change to EAPD mode */
2349 /* change to EAPD mode */
2358 /* change to EAPD mode */
2421 /* setting bits 1-5 disables DAC nids 0x02-0x06
2589 SND_PCI_QUIRK(0x1025, 0x0155, "Packard-Bell M5120", ALC882_FIXUP_PB_M5210),
2606 SND_PCI_QUIRK(0x1043, 0x8797, "ASUS TUF B550M-PLUS", ALCS1200A_FIXUP_MIC_VREF),
2607 SND_PCI_QUIRK(0x104d, 0x9043, "Sony Vaio VGC-LN51JGB", ALC882_FIXUP_NO_PRIMARY_HP),
2639 SND_PCI_QUIRK(0x13fe, 0x1009, "Advantech MIT-W101", ALC886_FIXUP_EAPD),
2640 SND_PCI_QUIRK(0x1458, 0xa002, "Gigabyte EP45-DS3/Z87X-UD3H", ALC889_FIXUP_FRONT_HP_NO_PRESENCE),
2641 SND_PCI_QUIRK(0x1458, 0xa0b8, "Gigabyte AZ370-Gaming", ALC1220_FIXUP_GB_DUAL_CODECS),
2645 SND_PCI_QUIRK(0x1462, 0x11f7, "MSI-GE63", ALC1220_FIXUP_CLEVO_P950),
2646 SND_PCI_QUIRK(0x1462, 0x1228, "MSI-GP63", ALC1220_FIXUP_CLEVO_P950),
2647 SND_PCI_QUIRK(0x1462, 0x1229, "MSI-GP73", ALC1220_FIXUP_CLEVO_P950),
2648 SND_PCI_QUIRK(0x1462, 0x1275, "MSI-GL63", ALC1220_FIXUP_CLEVO_P950),
2649 SND_PCI_QUIRK(0x1462, 0x1276, "MSI-GL73", ALC1220_FIXUP_CLEVO_P950),
2650 SND_PCI_QUIRK(0x1462, 0x1293, "MSI-GP65", ALC1220_FIXUP_CLEVO_P950),
2651 SND_PCI_QUIRK(0x1462, 0x7350, "MSI-7350", ALC889_FIXUP_CD),
2653 SND_PCI_QUIRK(0x1462, 0xda57, "MSI Z270-Gaming", ALC1220_FIXUP_GB_DUAL_CODECS),
2655 SND_PCI_QUIRK(0x147b, 0x107a, "Abit AW9D-MAX", ALC882_FIXUP_ABIT_AW9D_MAX),
2661 SND_PCI_QUIRK(0x1558, 0x65e5, "Clevo PC50D[PRS](?:-D|-G)?", ALC1220_FIXUP_CLEVO_PB51ED_PINS),
2665 SND_PCI_QUIRK(0x1558, 0x66a6, "Clevo PE60SN[CDE]-[GS]", ALC1220_FIXUP_CLEVO_PB51ED_PINS),
2668 SND_PCI_QUIRK(0x1558, 0x67e5, "Clevo PC70D[PRS](?:-D|-G)?", ALC1220_FIXUP_CLEVO_PB51ED_PINS),
2673 SND_PCI_QUIRK(0x1558, 0x7715, "Clevo X170KM-G", ALC1220_FIXUP_CLEVO_PB51ED),
2683 SND_PCI_QUIRK(0x1558, 0x96e1, "Clevo P960[ER][CDFN]-K", ALC1220_FIXUP_CLEVO_P950),
2685 SND_PCI_QUIRK(0x1558, 0x97e2, "Clevo P970RC-M", ALC1220_FIXUP_CLEVO_P950),
2695 {.id = ALC882_FIXUP_ABIT_AW9D_MAX, .name = "abit-aw9d"},
2696 {.id = ALC882_FIXUP_LENOVO_Y530, .name = "lenovo-y530"},
2697 {.id = ALC882_FIXUP_ACER_ASPIRE_7736, .name = "acer-aspire-7736"},
2698 {.id = ALC882_FIXUP_ASUS_W90V, .name = "asus-w90v"},
2700 {.id = ALC889_FIXUP_FRONT_HP_NO_PRESENCE, .name = "no-front-hp"},
2701 {.id = ALC889_FIXUP_VAIO_TT, .name = "vaio-tt"},
2703 {.id = ALC882_FIXUP_EAPD, .name = "alc882-eapd"},
2704 {.id = ALC883_FIXUP_EAPD, .name = "alc883-eapd"},
2708 {.id = ALC889_FIXUP_COEF, .name = "alc889-coef"},
2709 {.id = ALC882_FIXUP_ASUS_W2JC, .name = "asus-w2jc"},
2710 {.id = ALC882_FIXUP_ACER_ASPIRE_4930G, .name = "acer-aspire-4930g"},
2711 {.id = ALC882_FIXUP_ACER_ASPIRE_8930G, .name = "acer-aspire-8930g"},
2712 {.id = ALC883_FIXUP_ACER_EAPD, .name = "acer-aspire"},
2713 {.id = ALC885_FIXUP_MACPRO_GPIO, .name = "macpro-gpio"},
2714 {.id = ALC889_FIXUP_DAC_ROUTE, .name = "dac-route"},
2715 {.id = ALC889_FIXUP_MBP_VREF, .name = "mbp-vref"},
2716 {.id = ALC889_FIXUP_IMAC91_VREF, .name = "imac91-vref"},
2717 {.id = ALC889_FIXUP_MBA11_VREF, .name = "mba11-vref"},
2718 {.id = ALC889_FIXUP_MBA21_VREF, .name = "mba21-vref"},
2719 {.id = ALC889_FIXUP_MP11_VREF, .name = "mp11-vref"},
2720 {.id = ALC889_FIXUP_MP41_VREF, .name = "mp41-vref"},
2721 {.id = ALC882_FIXUP_INV_DMIC, .name = "inv-dmic"},
2722 {.id = ALC882_FIXUP_NO_PRIMARY_HP, .name = "no-primary-hp"},
2723 {.id = ALC887_FIXUP_ASUS_BASS, .name = "asus-bass"},
2724 {.id = ALC1220_FIXUP_GB_DUAL_CODECS, .name = "dual-codecs"},
2725 {.id = ALC1220_FIXUP_GB_X570, .name = "gb-x570"},
2726 {.id = ALC1220_FIXUP_CLEVO_P950, .name = "clevo-p950"},
2740 SND_HDA_PIN_QUIRK(0x10ec1220, 0x1462, "MS-7C35", ALC1220_FIXUP_CLEVO_P950,
2774 spec = codec->spec; in patch_alc882()
2776 switch (codec->core.vendor_id) { in patch_alc882()
2799 spec->gen.beep_nid = 0x01; in patch_alc882()
2806 if (!spec->gen.no_analog && spec->gen.beep_nid) { in patch_alc882()
2924 SND_PCI_QUIRK(0x17ff, 0x058d, "Benq T31-16", ALC262_FIXUP_BENQ_T31),
2930 {.id = ALC262_FIXUP_INV_DMIC, .name = "inv-dmic"},
2931 {.id = ALC262_FIXUP_FSC_H270, .name = "fsc-h270"},
2932 {.id = ALC262_FIXUP_FSC_S7110, .name = "fsc-s7110"},
2933 {.id = ALC262_FIXUP_HP_Z200, .name = "hp-z200"},
2935 {.id = ALC262_FIXUP_LENOVO_3000, .name = "lenovo-3000"},
2937 {.id = ALC262_FIXUP_BENQ_T31, .name = "benq-t31"},
2953 spec = codec->spec; in patch_alc262()
2954 spec->gen.shared_mic_vref_pin = 0x18; in patch_alc262()
2956 spec->shutup = alc_eapd_shutup; in patch_alc262()
2960 * under-run in patch_alc262()
2975 spec->gen.beep_nid = 0x01; in patch_alc262()
2982 if (!spec->gen.no_analog && spec->gen.beep_nid) { in patch_alc262()
3008 mutex_lock(&codec->control_mutex); in alc268_beep_switch_put()
3009 pval = kcontrol->private_value; in alc268_beep_switch_put()
3010 kcontrol->private_value = (pval & ~0xff) | 0x0f; in alc268_beep_switch_put()
3013 kcontrol->private_value = (pval & ~0xff) | 0x10; in alc268_beep_switch_put()
3016 kcontrol->private_value = pval; in alc268_beep_switch_put()
3017 mutex_unlock(&codec->control_mutex); in alc268_beep_switch_put()
3070 {.id = ALC268_FIXUP_INV_DMIC, .name = "inv-dmic"},
3071 {.id = ALC268_FIXUP_HP_EAPD, .name = "hp-eapd"},
3102 /* ALC268 has no aa-loopback mixer */ in patch_alc268()
3107 spec = codec->spec; in patch_alc268()
3109 spec->gen.beep_nid = 0x01; in patch_alc268()
3111 spec->shutup = alc_eapd_shutup; in patch_alc268()
3123 if (err > 0 && !spec->gen.no_analog && in patch_alc268()
3124 spec->gen.autocfg.speaker_pins[0] != 0x1d) { in patch_alc268()
3126 if (!snd_hda_gen_add_kctl(&spec->gen, NULL, in patch_alc268()
3128 err = -ENOMEM; in patch_alc268()
3163 /* different alc269-variants */
3197 struct alc_spec *spec = codec->spec; in alc269_parse_auto_config()
3200 switch (spec->codec_variant) { in alc269_parse_auto_config()
3248 if (jack->unsol_res & (7 << 13)) in alc_headset_btn_callback()
3251 if (jack->unsol_res & (1 << 16 | 3 << 8)) in alc_headset_btn_callback()
3255 if (jack->unsol_res & (7 << 23)) in alc_headset_btn_callback()
3259 if (jack->unsol_res & (7 << 10)) in alc_headset_btn_callback()
3262 snd_hda_jack_set_button_state(codec, jack->nid, report); in alc_headset_btn_callback()
3267 struct alc_spec *spec = codec->spec; in alc_disable_headset_jack_key()
3269 if (!spec->has_hs_key) in alc_disable_headset_jack_key()
3272 switch (codec->core.vendor_id) { in alc_disable_headset_jack_key()
3297 struct alc_spec *spec = codec->spec; in alc_enable_headset_jack_key()
3299 if (!spec->has_hs_key) in alc_enable_headset_jack_key()
3302 switch (codec->core.vendor_id) { in alc_enable_headset_jack_key()
3328 struct alc_spec *spec = codec->spec; in alc_fixup_headset_jack()
3333 spec->has_hs_key = 1; in alc_fixup_headset_jack()
3358 struct alc_spec *spec = codec->spec; in alc269_shutup()
3360 if (spec->codec_variant == ALC269_TYPE_ALC269VB) in alc269_shutup()
3362 if (spec->codec_variant == ALC269_TYPE_ALC269VB && in alc269_shutup()
3409 struct alc_spec *spec = codec->spec; in alc282_init()
3422 /* Headphone capless set to high power mode */ in alc282_init()
3440 /* Headphone capless set to normal mode */ in alc282_init()
3446 struct alc_spec *spec = codec->spec; in alc282_shutup()
3469 if (!spec->no_shutup_pins) in alc282_shutup()
3510 WRITE_COEF(0x49, 0x0), /* test mode */
3525 struct alc_spec *spec = codec->spec; in alc283_init()
3538 /* Headphone capless set to high power mode */ in alc283_init()
3555 /* Headphone capless set to normal mode */ in alc283_init()
3561 struct alc_spec *spec = codec->spec; in alc283_shutup()
3583 if (!spec->no_shutup_pins) in alc283_shutup()
3598 struct alc_spec *spec = codec->spec; in alc256_init()
3602 if (spec->ultra_low_power) { in alc256_init()
3639 * Documentation/sound/hd-audio/realtek-pc-beep.rst for details of in alc256_init()
3647 struct alc_spec *spec = codec->spec; in alc256_shutup()
3670 if (spec->en_3kpull_low) in alc256_shutup()
3673 if (!spec->no_shutup_pins) in alc256_shutup()
3682 if (spec->ultra_low_power) { in alc256_shutup()
3695 struct alc_spec *spec = codec->spec; in alc285_hp_init()
3722 alc_write_coef_idx(codec, 0x67, 0x0); /* Set HP depop to manual mode */ in alc285_hp_init()
3745 struct alc_spec *spec = codec->spec; in alc225_init()
3749 if (spec->ultra_low_power) { in alc225_init()
3756 if (spec->codec_variant != ALC269_TYPE_ALC287 && in alc225_init()
3757 spec->codec_variant != ALC269_TYPE_ALC245) in alc225_init()
3759 if (!spec->done_hp_init || in alc225_init()
3763 spec->done_hp_init = true; in alc225_init()
3799 struct alc_spec *spec = codec->spec; in alc225_shutup()
3837 if (spec->ultra_low_power) { in alc225_shutup()
3849 struct alc_spec *spec = codec->spec; in alc_default_init()
3876 struct alc_spec *spec = codec->spec; in alc_default_shutup()
3895 if (!spec->no_shutup_pins) in alc_default_shutup()
3907 struct alc_spec *spec = codec->spec; in alc294_hp_init()
3919 if (!spec->no_shutup_pins) in alc294_hp_init()
3923 alc_update_coef_idx(codec, 0x6f, 0x000f, 0);/* Set HP depop to manual mode */ in alc294_hp_init()
3932 /* Set HP depop to auto mode */ in alc294_hp_init()
3939 struct alc_spec *spec = codec->spec; in alc294_init()
3942 if (!spec->done_hp_init || in alc294_init()
3943 codec->core.dev.power.power_state.event == PM_EVENT_RESTORE) { in alc294_init()
3945 spec->done_hp_init = true; in alc294_init()
4044 struct alc_spec *spec = codec->spec; in alc269_suspend()
4046 if (spec->has_alc5505_dsp) in alc269_suspend()
4054 struct alc_spec *spec = codec->spec; in alc269_resume()
4056 if (spec->codec_variant == ALC269_TYPE_ALC269VB) in alc269_resume()
4058 if (spec->codec_variant == ALC269_TYPE_ALC269VB && in alc269_resume()
4063 codec->patch_ops.init(codec); in alc269_resume()
4065 if (spec->codec_variant == ALC269_TYPE_ALC269VB) in alc269_resume()
4067 if (spec->codec_variant == ALC269_TYPE_ALC269VB && in alc269_resume()
4079 if (spec->gpio_data) in alc269_resume()
4082 if (spec->has_alc5505_dsp) in alc269_resume()
4091 struct alc_spec *spec = codec->spec; in alc269_fixup_pincfg_no_hp_to_lineout()
4094 spec->parse_flags = HDA_PINCFG_NO_HP_FIXUP; in alc269_fixup_pincfg_no_hp_to_lineout()
4120 struct alc_spec *spec = codec->spec; in alc269_fixup_headset_mic()
4123 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc269_fixup_headset_mic()
4136 if (strcmp(codec->core.chip_name, "ALC271X") && in alc271_fixup_dmic()
4137 strcmp(codec->core.chip_name, "ALC269VB")) in alc271_fixup_dmic()
4156 struct alc_spec *spec = codec->spec; in alc269_fixup_pcm_44k()
4164 spec->gen.stream_analog_playback = &alc269_44k_pcm_analog_playback; in alc269_fixup_pcm_44k()
4165 spec->gen.stream_analog_capture = &alc269_44k_pcm_analog_capture; in alc269_fixup_pcm_44k()
4171 /* The digital-mic unit sends PDM (differential signal) instead of in alc269_fixup_stereo_dmic()
4191 struct alc_spec *spec = codec->spec; in alc269_fixup_quanta_mute()
4194 spec->gen.automute_hook = alc269_quanta_automute; in alc269_fixup_quanta_mute()
4200 struct alc_spec *spec = codec->spec; in alc269_x101_hp_automute_hook()
4205 vref = spec->gen.hp_jack_present ? PIN_VREF80 : 0; in alc269_x101_hp_automute_hook()
4234 alc_write_coef_idx(codec, 0x23, initval->value_0x23); in alc298_huawei_mbx_stereo_seq()
4236 if (initval->value_0x23 != 0x1e) in alc298_huawei_mbx_stereo_seq()
4237 alc_write_coef_idx(codec, 0x25, initval->value_0x25); in alc298_huawei_mbx_stereo_seq()
4276 for (seq = dac_init; seq->value_0x23; seq++) in alc298_fixup_huawei_mbx_stereo()
4283 struct alc_spec *spec = codec->spec; in alc269_fixup_x101_headset_mic()
4285 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc269_fixup_x101_headset_mic()
4286 spec->gen.hp_automute_hook = alc269_x101_hp_automute_hook; in alc269_fixup_x101_headset_mic()
4308 /* update mute-LED according to the speaker mute state via mic VREF pin */
4312 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in vref_mute_led_set()
4313 struct alc_spec *spec = codec->spec; in vref_mute_led_set()
4315 alc_update_vref_led(codec, spec->mute_led_nid, in vref_mute_led_set()
4316 spec->mute_led_polarity, brightness); in vref_mute_led_set()
4325 struct alc_spec *spec = codec->spec; in led_power_filter()
4328 (nid != spec->mute_led_nid && nid != spec->cap_mute_led_nid)) in led_power_filter()
4341 struct alc_spec *spec = codec->spec; in alc269_fixup_hp_mute_led()
4349 if (sscanf(dev->name, "HP_Mute_LED_%d_%x", &pol, &pin) != 2) in alc269_fixup_hp_mute_led()
4353 spec->mute_led_polarity = pol; in alc269_fixup_hp_mute_led()
4354 spec->mute_led_nid = pin - 0x0a + 0x18; in alc269_fixup_hp_mute_led()
4356 codec->power_filter = led_power_filter; in alc269_fixup_hp_mute_led()
4358 "Detected mute LED for %x:%d\n", spec->mute_led_nid, in alc269_fixup_hp_mute_led()
4359 spec->mute_led_polarity); in alc269_fixup_hp_mute_led()
4368 struct alc_spec *spec = codec->spec; in alc269_fixup_hp_mute_led_micx()
4371 spec->mute_led_polarity = 0; in alc269_fixup_hp_mute_led_micx()
4372 spec->mute_led_nid = pin; in alc269_fixup_hp_mute_led_micx()
4374 codec->power_filter = led_power_filter; in alc269_fixup_hp_mute_led_micx()
4402 alc_update_gpio_data(codec, mask, !enabled); /* muted -> LED on */ in alc_update_gpio_led()
4409 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in gpio_mute_led_set()
4410 struct alc_spec *spec = codec->spec; in gpio_mute_led_set()
4412 alc_update_gpio_led(codec, spec->gpio_mute_led_mask, in gpio_mute_led_set()
4413 spec->mute_led_polarity, !brightness); in gpio_mute_led_set()
4417 /* turn on/off mic-mute LED via GPIO per capture hook */
4421 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in micmute_led_set()
4422 struct alc_spec *spec = codec->spec; in micmute_led_set()
4424 alc_update_gpio_led(codec, spec->gpio_mic_led_mask, in micmute_led_set()
4425 spec->micmute_led_polarity, !brightness); in micmute_led_set()
4429 /* setup mute and mic-mute GPIO bits, add hooks appropriately */
4435 struct alc_spec *spec = codec->spec; in alc_fixup_hp_gpio_led()
4442 spec->gpio_mute_led_mask = mute_mask; in alc_fixup_hp_gpio_led()
4446 spec->gpio_mic_led_mask = micmute_mask; in alc_fixup_hp_gpio_led()
4484 struct alc_spec *spec = codec->spec; in alc245_fixup_hp_gpio_led()
4487 spec->micmute_led_polarity = 1; in alc245_fixup_hp_gpio_led()
4491 /* turn on/off mic-mute LED per capture hook via VREF change */
4495 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in vref_micmute_led_set()
4496 struct alc_spec *spec = codec->spec; in vref_micmute_led_set()
4498 alc_update_vref_led(codec, spec->cap_mute_led_nid, in vref_micmute_led_set()
4499 spec->micmute_led_polarity, brightness); in vref_micmute_led_set()
4506 struct alc_spec *spec = codec->spec; in alc269_fixup_hp_gpio_mic1_led()
4513 spec->gpio_mask |= 0x10; in alc269_fixup_hp_gpio_mic1_led()
4514 spec->gpio_dir |= 0x10; in alc269_fixup_hp_gpio_mic1_led()
4515 spec->cap_mute_led_nid = 0x18; in alc269_fixup_hp_gpio_mic1_led()
4517 codec->power_filter = led_power_filter; in alc269_fixup_hp_gpio_mic1_led()
4524 struct alc_spec *spec = codec->spec; in alc280_fixup_hp_gpio4()
4528 spec->cap_mute_led_nid = 0x18; in alc280_fixup_hp_gpio4()
4530 codec->power_filter = led_power_filter; in alc280_fixup_hp_gpio4()
4540 struct alc_spec *spec = codec->spec; in alc245_fixup_hp_x360_amp()
4544 spec->gpio_mask |= 0x01; in alc245_fixup_hp_x360_amp()
4545 spec->gpio_dir |= 0x01; in alc245_fixup_hp_x360_amp()
4576 struct alc_spec *spec = codec->spec; in alc274_fixup_hp_envy_gpio()
4579 spec->gpio_mask |= 0x04; in alc274_fixup_hp_envy_gpio()
4580 spec->gpio_dir |= 0x04; in alc274_fixup_hp_envy_gpio()
4581 spec->gen.pcm_playback_hook = alc274_hp_envy_pcm_hook; in alc274_fixup_hp_envy_gpio()
4592 alc_update_coef_idx(codec, led->idx, led->mask, in alc_update_coef_led()
4593 on ? led->on : led->off); in alc_update_coef_led()
4596 /* update mute-LED according to the speaker mute state via COEF bit */
4600 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in coef_mute_led_set()
4601 struct alc_spec *spec = codec->spec; in coef_mute_led_set()
4603 alc_update_coef_led(codec, &spec->mute_led_coef, in coef_mute_led_set()
4604 spec->mute_led_polarity, brightness); in coef_mute_led_set()
4612 struct alc_spec *spec = codec->spec; in alc285_fixup_hp_mute_led_coefbit()
4615 spec->mute_led_polarity = 0; in alc285_fixup_hp_mute_led_coefbit()
4616 spec->mute_led_coef.idx = 0x0b; in alc285_fixup_hp_mute_led_coefbit()
4617 spec->mute_led_coef.mask = 1 << 3; in alc285_fixup_hp_mute_led_coefbit()
4618 spec->mute_led_coef.on = 1 << 3; in alc285_fixup_hp_mute_led_coefbit()
4619 spec->mute_led_coef.off = 0; in alc285_fixup_hp_mute_led_coefbit()
4628 struct alc_spec *spec = codec->spec; in alc236_fixup_hp_mute_led_coefbit()
4631 spec->mute_led_polarity = 0; in alc236_fixup_hp_mute_led_coefbit()
4632 spec->mute_led_coef.idx = 0x34; in alc236_fixup_hp_mute_led_coefbit()
4633 spec->mute_led_coef.mask = 1 << 5; in alc236_fixup_hp_mute_led_coefbit()
4634 spec->mute_led_coef.on = 0; in alc236_fixup_hp_mute_led_coefbit()
4635 spec->mute_led_coef.off = 1 << 5; in alc236_fixup_hp_mute_led_coefbit()
4643 struct alc_spec *spec = codec->spec; in alc236_fixup_hp_mute_led_coefbit2()
4646 spec->mute_led_polarity = 0; in alc236_fixup_hp_mute_led_coefbit2()
4647 spec->mute_led_coef.idx = 0x07; in alc236_fixup_hp_mute_led_coefbit2()
4648 spec->mute_led_coef.mask = 1; in alc236_fixup_hp_mute_led_coefbit2()
4649 spec->mute_led_coef.on = 1; in alc236_fixup_hp_mute_led_coefbit2()
4650 spec->mute_led_coef.off = 0; in alc236_fixup_hp_mute_led_coefbit2()
4659 struct alc_spec *spec = codec->spec; in alc245_fixup_hp_mute_led_coefbit()
4662 spec->mute_led_polarity = 0; in alc245_fixup_hp_mute_led_coefbit()
4663 spec->mute_led_coef.idx = 0x0b; in alc245_fixup_hp_mute_led_coefbit()
4664 spec->mute_led_coef.mask = 3 << 2; in alc245_fixup_hp_mute_led_coefbit()
4665 spec->mute_led_coef.on = 2 << 2; in alc245_fixup_hp_mute_led_coefbit()
4666 spec->mute_led_coef.off = 1 << 2; in alc245_fixup_hp_mute_led_coefbit()
4671 /* turn on/off mic-mute LED per capture hook by coef bit */
4675 struct hda_codec *codec = dev_to_hda_codec(led_cdev->dev->parent); in coef_micmute_led_set()
4676 struct alc_spec *spec = codec->spec; in coef_micmute_led_set()
4678 alc_update_coef_led(codec, &spec->mic_led_coef, in coef_micmute_led_set()
4679 spec->micmute_led_polarity, brightness); in coef_micmute_led_set()
4686 struct alc_spec *spec = codec->spec; in alc285_fixup_hp_coef_micmute_led()
4689 spec->mic_led_coef.idx = 0x19; in alc285_fixup_hp_coef_micmute_led()
4690 spec->mic_led_coef.mask = 1 << 13; in alc285_fixup_hp_coef_micmute_led()
4691 spec->mic_led_coef.on = 1 << 13; in alc285_fixup_hp_coef_micmute_led()
4692 spec->mic_led_coef.off = 0; in alc285_fixup_hp_coef_micmute_led()
4700 struct alc_spec *spec = codec->spec; in alc285_fixup_hp_gpio_micmute_led()
4703 spec->micmute_led_polarity = 1; in alc285_fixup_hp_gpio_micmute_led()
4710 struct alc_spec *spec = codec->spec; in alc236_fixup_hp_coef_micmute_led()
4713 spec->mic_led_coef.idx = 0x35; in alc236_fixup_hp_coef_micmute_led()
4714 spec->mic_led_coef.mask = 3 << 2; in alc236_fixup_hp_coef_micmute_led()
4715 spec->mic_led_coef.on = 2 << 2; in alc236_fixup_hp_coef_micmute_led()
4716 spec->mic_led_coef.off = 1 << 2; in alc236_fixup_hp_coef_micmute_led()
4745 struct alc_spec *spec = codec->spec; in alc236_fixup_hp_micmute_led_vref()
4748 spec->cap_mute_led_nid = 0x1a; in alc236_fixup_hp_micmute_led_vref()
4750 codec->power_filter = led_power_filter; in alc236_fixup_hp_micmute_led_vref()
4845 struct alc_spec *spec = codec->spec; in alc298_samsung_v2_enable_amps()
4851 for (i = 0; i < spec->num_speaker_amps; i++) { in alc298_samsung_v2_enable_amps()
4862 struct alc_spec *spec = codec->spec; in alc298_samsung_v2_disable_amps()
4868 for (i = 0; i < spec->num_speaker_amps; i++) { in alc298_samsung_v2_disable_amps()
4892 struct alc_spec *spec = codec->spec; in alc298_samsung_v2_init_amps()
4896 spec->num_speaker_amps = num_speaker_amps; in alc298_samsung_v2_init_amps()
4902 for (i = 0; i < spec->num_speaker_amps; i++) { in alc298_samsung_v2_init_amps()
4914 spec->gen.pcm_playback_hook = alc298_samsung_v2_playback_hook; in alc298_samsung_v2_init_amps()
4935 struct alc_spec *spec = codec->spec; in gpio2_mic_hotkey_event()
4939 input_report_key(spec->kb_dev, spec->alc_mute_keycode_map[ALC_KEY_MICMUTE_INDEX], 1); in gpio2_mic_hotkey_event()
4940 input_sync(spec->kb_dev); in gpio2_mic_hotkey_event()
4941 input_report_key(spec->kb_dev, spec->alc_mute_keycode_map[ALC_KEY_MICMUTE_INDEX], 0); in gpio2_mic_hotkey_event()
4942 input_sync(spec->kb_dev); in gpio2_mic_hotkey_event()
4947 struct alc_spec *spec = codec->spec; in alc_register_micmute_input_device()
4950 spec->kb_dev = input_allocate_device(); in alc_register_micmute_input_device()
4951 if (!spec->kb_dev) { in alc_register_micmute_input_device()
4953 return -ENOMEM; in alc_register_micmute_input_device()
4956 spec->alc_mute_keycode_map[ALC_KEY_MICMUTE_INDEX] = KEY_MICMUTE; in alc_register_micmute_input_device()
4958 spec->kb_dev->name = "Microphone Mute Button"; in alc_register_micmute_input_device()
4959 spec->kb_dev->evbit[0] = BIT_MASK(EV_KEY); in alc_register_micmute_input_device()
4960 spec->kb_dev->keycodesize = sizeof(spec->alc_mute_keycode_map[0]); in alc_register_micmute_input_device()
4961 spec->kb_dev->keycodemax = ARRAY_SIZE(spec->alc_mute_keycode_map); in alc_register_micmute_input_device()
4962 spec->kb_dev->keycode = spec->alc_mute_keycode_map; in alc_register_micmute_input_device()
4963 for (i = 0; i < ARRAY_SIZE(spec->alc_mute_keycode_map); i++) in alc_register_micmute_input_device()
4964 set_bit(spec->alc_mute_keycode_map[i], spec->kb_dev->keybit); in alc_register_micmute_input_device()
4966 if (input_register_device(spec->kb_dev)) { in alc_register_micmute_input_device()
4968 input_free_device(spec->kb_dev); in alc_register_micmute_input_device()
4969 spec->kb_dev = NULL; in alc_register_micmute_input_device()
4970 return -ENOMEM; in alc_register_micmute_input_device()
4984 struct alc_spec *spec = codec->spec; in alc280_fixup_hp_gpio2_mic_hotkey()
4988 spec->init_amp = ALC_INIT_DEFAULT; in alc280_fixup_hp_gpio2_mic_hotkey()
4992 spec->gpio_mask |= 0x06; in alc280_fixup_hp_gpio2_mic_hotkey()
4993 spec->gpio_dir |= 0x02; in alc280_fixup_hp_gpio2_mic_hotkey()
4994 spec->gpio_data |= 0x02; in alc280_fixup_hp_gpio2_mic_hotkey()
4995 snd_hda_codec_write_cache(codec, codec->core.afg, 0, in alc280_fixup_hp_gpio2_mic_hotkey()
4997 snd_hda_jack_detect_enable_callback(codec, codec->core.afg, in alc280_fixup_hp_gpio2_mic_hotkey()
5002 if (!spec->kb_dev) in alc280_fixup_hp_gpio2_mic_hotkey()
5007 input_unregister_device(spec->kb_dev); in alc280_fixup_hp_gpio2_mic_hotkey()
5008 spec->kb_dev = NULL; in alc280_fixup_hp_gpio2_mic_hotkey()
5018 struct alc_spec *spec = codec->spec; in alc233_fixup_lenovo_line2_mic_hotkey()
5022 spec->init_amp = ALC_INIT_DEFAULT; in alc233_fixup_lenovo_line2_mic_hotkey()
5031 if (!spec->kb_dev) in alc233_fixup_lenovo_line2_mic_hotkey()
5036 input_unregister_device(spec->kb_dev); in alc233_fixup_lenovo_line2_mic_hotkey()
5037 spec->kb_dev = NULL; in alc233_fixup_lenovo_line2_mic_hotkey()
5048 struct alc_spec *spec = codec->spec; in alc269_fixup_hp_line1_mic1_led()
5052 spec->cap_mute_led_nid = 0x18; in alc269_fixup_hp_line1_mic1_led()
5094 struct alc_spec *spec = codec->spec; in alc_headset_mode_unplugged()
5097 WRITE_COEF(0x45, 0xd089), /* UAJ function set to menual mode */ in alc_headset_mode_unplugged()
5105 WRITE_COEF(0x45, 0xd089), /* UAJ function set to menual mode */ in alc_headset_mode_unplugged()
5144 UPDATE_COEF(0x1a, 1<<3, 1<<3), /* Combo JD gating with LINE1-VREFO */ in alc_headset_mode_unplugged()
5169 if (spec->no_internal_mic_pin) { in alc_headset_mode_unplugged()
5174 switch (codec->core.vendor_id) { in alc_headset_mode_unplugged()
5225 codec_dbg(codec, "Headset jack set to unplugged mode.\n"); in alc_headset_mode_unplugged()
5267 UPDATE_COEF(0x1a, 1<<3, 0), /* Combo JD gating without LINE1-VREFO */ in alc_headset_mode_mic_in()
5289 switch (codec->core.vendor_id) { in alc_headset_mode_mic_in()
5332 /* Set to TRS mode */ in alc_headset_mode_mic_in()
5365 codec_dbg(codec, "Headset jack set to mic-in mode.\n"); in alc_headset_mode_mic_in()
5417 UPDATE_COEF(0x1a, 1<<3, 0), /* Combo JD gating without LINE1-VREFO */ in alc_headset_mode_default()
5434 switch (codec->core.vendor_id) { in alc_headset_mode_default()
5485 codec_dbg(codec, "Headset jack set to headphone (default) mode.\n"); in alc_headset_mode_default()
5545 switch (codec->core.vendor_id) { in alc_headset_mode_ctia()
5609 codec_dbg(codec, "Headset jack set to iPhone-style headset mode.\n"); in alc_headset_mode_ctia()
5662 switch (codec->core.vendor_id) { in alc_headset_mode_omtp()
5712 codec_dbg(codec, "Headset jack set to Nokia-style headset mode.\n"); in alc_headset_mode_omtp()
5719 struct alc_spec *spec = codec->spec; in alc_determine_headset_type()
5758 if (spec->no_internal_mic_pin) { in alc_determine_headset_type()
5763 switch (codec->core.vendor_id) { in alc_determine_headset_type()
5904 codec_dbg(codec, "Headset jack detected iPhone-style headset: %s\n", in alc_determine_headset_type()
5906 spec->current_headset_type = is_ctia ? ALC_HEADSET_TYPE_CTIA : ALC_HEADSET_TYPE_OMTP; in alc_determine_headset_type()
5911 struct alc_spec *spec = codec->spec; in alc_update_headset_mode()
5913 hda_nid_t mux_pin = spec->gen.imux_pins[spec->gen.cur_mux[0]]; in alc_update_headset_mode()
5920 else if (mux_pin == spec->headset_mic_pin) in alc_update_headset_mode()
5922 else if (mux_pin == spec->headphone_mic_pin) in alc_update_headset_mode()
5927 if (new_headset_mode == spec->current_headset_mode) { in alc_update_headset_mode()
5935 spec->current_headset_mode = ALC_HEADSET_MODE_UNKNOWN; in alc_update_headset_mode()
5936 spec->current_headset_type = ALC_HEADSET_TYPE_UNKNOWN; in alc_update_headset_mode()
5937 spec->gen.hp_jack_present = false; in alc_update_headset_mode()
5940 if (spec->current_headset_type == ALC_HEADSET_TYPE_UNKNOWN) in alc_update_headset_mode()
5942 if (spec->current_headset_type == ALC_HEADSET_TYPE_CTIA) in alc_update_headset_mode()
5944 else if (spec->current_headset_type == ALC_HEADSET_TYPE_OMTP) in alc_update_headset_mode()
5946 spec->gen.hp_jack_present = true; in alc_update_headset_mode()
5949 alc_headset_mode_mic_in(codec, hp_pin, spec->headphone_mic_pin); in alc_update_headset_mode()
5950 spec->gen.hp_jack_present = false; in alc_update_headset_mode()
5954 spec->gen.hp_jack_present = true; in alc_update_headset_mode()
5960 if (spec->headphone_mic_pin && spec->headphone_mic_pin != hp_pin) in alc_update_headset_mode()
5961 snd_hda_set_pin_ctl_cache(codec, spec->headphone_mic_pin, in alc_update_headset_mode()
5964 spec->current_headset_mode = new_headset_mode; in alc_update_headset_mode()
5986 struct alc_spec *spec = codec->spec; in alc_probe_headset_mode()
5987 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in alc_probe_headset_mode()
5990 for (i = 0; i < cfg->num_inputs; i++) { in alc_probe_headset_mode()
5991 if (cfg->inputs[i].is_headset_mic && !spec->headset_mic_pin) in alc_probe_headset_mode()
5992 spec->headset_mic_pin = cfg->inputs[i].pin; in alc_probe_headset_mode()
5993 if (cfg->inputs[i].is_headphone_mic && !spec->headphone_mic_pin) in alc_probe_headset_mode()
5994 spec->headphone_mic_pin = cfg->inputs[i].pin; in alc_probe_headset_mode()
5997 WARN_ON(spec->gen.cap_sync_hook); in alc_probe_headset_mode()
5998 spec->gen.cap_sync_hook = alc_update_headset_mode_hook; in alc_probe_headset_mode()
5999 spec->gen.automute_hook = alc_update_headset_mode; in alc_probe_headset_mode()
6000 spec->gen.hp_automute_hook = alc_update_headset_jack_cb; in alc_probe_headset_mode()
6006 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode()
6010 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC | HDA_PINCFG_HEADPHONE_MIC; in alc_fixup_headset_mode()
6017 spec->current_headset_mode = ALC_HEADSET_MODE_UNKNOWN; in alc_fixup_headset_mode()
6018 spec->current_headset_type = ALC_HEADSET_TYPE_UNKNOWN; in alc_fixup_headset_mode()
6029 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode_no_hp_mic()
6030 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc_fixup_headset_mode_no_hp_mic()
6055 switch (codec->core.vendor_id) { in alc255_set_default_jack_type()
6082 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode_alc255_no_hp_mic()
6083 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc_fixup_headset_mode_alc255_no_hp_mic()
6093 struct alc_spec *spec = codec->spec; in alc288_update_headset_jack_cb()
6097 alc_update_gpio_data(codec, 0x40, spec->gen.hp_jack_present); in alc288_update_headset_jack_cb()
6105 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode_dell_alc288()
6107 spec->gpio_mask |= 0x40; in alc_fixup_headset_mode_dell_alc288()
6108 spec->gpio_dir |= 0x40; in alc_fixup_headset_mode_dell_alc288()
6109 spec->gen.hp_automute_hook = alc288_update_headset_jack_cb; in alc_fixup_headset_mode_dell_alc288()
6117 struct alc_spec *spec = codec->spec; in alc_fixup_auto_mute_via_amp()
6118 spec->gen.auto_mute_via_amp = 1; in alc_fixup_auto_mute_via_amp()
6126 struct alc_spec *spec = codec->spec; in alc_fixup_no_shutup()
6127 spec->no_shutup_pins = 1; in alc_fixup_no_shutup()
6135 struct alc_spec *spec = codec->spec; in alc_fixup_disable_aamix()
6136 /* Disable AA-loopback as it causes white noise */ in alc_fixup_disable_aamix()
6137 spec->gen.mixer_nid = 0; in alc_fixup_disable_aamix()
6150 struct alc_spec *spec = codec->spec; in alc_fixup_tpt440_dock()
6153 spec->parse_flags = HDA_PINCFG_NO_HP_FIXUP; in alc_fixup_tpt440_dock()
6154 codec->power_save_node = 0; /* avoid click noises */ in alc_fixup_tpt440_dock()
6167 struct alc_spec *spec = codec->spec; in alc_fixup_tpt470_dock()
6170 spec->parse_flags = HDA_PINCFG_NO_HP_FIXUP; in alc_fixup_tpt470_dock()
6193 struct alc_spec *spec = codec->spec; in alc_fixup_tpt470_dacs()
6196 spec->gen.preferred_dacs = preferred_pairs; in alc_fixup_tpt470_dacs()
6205 struct alc_spec *spec = codec->spec; in alc295_fixup_asus_dacs()
6208 spec->gen.preferred_dacs = preferred_pairs; in alc295_fixup_asus_dacs()
6213 struct alc_spec *spec = codec->spec; in alc_shutup_dell_xps13()
6225 struct alc_spec *spec = codec->spec; in alc_fixup_dell_xps13()
6226 struct hda_input_mux *imux = &spec->gen.input_mux; in alc_fixup_dell_xps13()
6231 /* mic pin 0x19 must be initialized with Vref Hi-Z, otherwise in alc_fixup_dell_xps13()
6235 spec->shutup = alc_shutup_dell_xps13; in alc_fixup_dell_xps13()
6239 for (i = 0; i < imux->num_items; i++) { in alc_fixup_dell_xps13()
6240 if (spec->gen.imux_pins[i] == 0x12) { in alc_fixup_dell_xps13()
6241 spec->gen.cur_mux[0] = i; in alc_fixup_dell_xps13()
6252 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mode_alc662()
6255 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc_fixup_headset_mode_alc662()
6256 spec->gen.hp_mic = 1; /* Mic-in is same pin as headphone */ in alc_fixup_headset_mode_alc662()
6258 /* Disable boost for mic-in permanently. (This code is only called in alc_fixup_headset_mode_alc662()
6280 struct alc_spec *spec = codec->spec; in find_ext_mic_pin()
6281 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in find_ext_mic_pin()
6286 for (i = 0; i < cfg->num_inputs; i++) { in find_ext_mic_pin()
6287 if (cfg->inputs[i].type != AUTO_PIN_MIC) in find_ext_mic_pin()
6289 nid = cfg->inputs[i].pin; in find_ext_mic_pin()
6303 struct alc_spec *spec = codec->spec; in alc271_hp_gate_mic_jack()
6319 struct alc_spec *spec = codec->spec; in alc269_fixup_limit_int_mic_boost()
6320 struct auto_pin_cfg *cfg = &spec->gen.autocfg; in alc269_fixup_limit_int_mic_boost()
6330 for (i = 0; i < cfg->num_inputs; i++) { in alc269_fixup_limit_int_mic_boost()
6331 hda_nid_t nid = cfg->inputs[i].pin; in alc269_fixup_limit_int_mic_boost()
6333 if (cfg->inputs[i].type != AUTO_PIN_MIC) in alc269_fixup_limit_int_mic_boost()
6350 struct alc_spec *spec = codec->spec; in alc283_hp_automute_hook()
6356 vref = spec->gen.hp_jack_present ? PIN_VREF80 : 0; in alc283_hp_automute_hook()
6366 struct alc_spec *spec = codec->spec; in alc283_fixup_chromebook()
6371 /* Disable AA-loopback as it causes white noise */ in alc283_fixup_chromebook()
6372 spec->gen.mixer_nid = 0; in alc283_fixup_chromebook()
6375 /* MIC2-VREF control */ in alc283_fixup_chromebook()
6376 /* Set to manual mode */ in alc283_fixup_chromebook()
6387 struct alc_spec *spec = codec->spec; in alc283_fixup_sense_combo_jack()
6391 spec->gen.hp_automute_hook = alc283_hp_automute_hook; in alc283_fixup_sense_combo_jack()
6394 /* MIC2-VREF control */ in alc283_fixup_sense_combo_jack()
6395 /* Set to manual mode */ in alc283_fixup_sense_combo_jack()
6404 struct alc_spec *spec = codec->spec; in asus_tx300_automute()
6407 spec->gen.mute_bits |= (1ULL << 0x14); in asus_tx300_automute()
6413 struct alc_spec *spec = codec->spec; in alc282_fixup_asus_tx300()
6421 spec->init_amp = ALC_INIT_DEFAULT; in alc282_fixup_asus_tx300()
6425 spec->gen.auto_mute_via_amp = 1; in alc282_fixup_asus_tx300()
6426 spec->gen.automute_hook = asus_tx300_automute; in alc282_fixup_asus_tx300()
6431 spec->init_amp = ALC_INIT_DEFAULT; in alc282_fixup_asus_tx300()
6464 Amp-out capability. we change the speaker's route to: in alc298_fixup_speaker_volume()
6465 Node 0x02 (Audio Output) -> Node 0x0c (Audio Mixer) -> Node 0x17 ( in alc298_fixup_speaker_volume()
6466 Pin Complex), since Node 0x02 has Amp-out caps, we can adjust in alc298_fixup_speaker_volume()
6494 /* disable DAC3 (0x06) selection on NID 0x15 - share Speaker/Bass Speaker DAC 0x03 */
6508 struct alc_spec *spec = codec->spec; in alc280_hp_gpio4_automute_hook()
6512 alc_update_gpio_led(codec, 0x10, spec->mute_led_polarity, in alc280_hp_gpio4_automute_hook()
6513 !spec->gen.hp_jack_present); in alc280_hp_gpio4_automute_hook()
6526 struct alc_spec *spec = codec->spec; in alc280_fixup_hp_9480m()
6531 spec->gpio_mask |= 0x10; in alc280_fixup_hp_9480m()
6532 spec->gpio_dir |= 0x10; in alc280_fixup_hp_9480m()
6533 spec->gen.hp_automute_hook = alc280_hp_gpio4_automute_hook; in alc280_fixup_hp_9480m()
6541 struct alc_spec *spec = codec->spec; in alc275_fixup_gpio4_off()
6544 spec->gpio_mask |= 0x04; in alc275_fixup_gpio4_off()
6545 spec->gpio_dir |= 0x04; in alc275_fixup_gpio4_off()
6552 * DAC1 (NID 0x02) -> Speaker (NID 0x14); some eq applied secretly
6553 * DAC2 (NID 0x03) -> Bass (NID 0x17) & Headphone (NID 0x21); sharing a DAC
6554 * DAC3 (NID 0x06) -> Unused, due to the lack of volume amp
6563 struct alc_spec *spec = codec->spec; in alc285_fixup_thinkpad_x1_gen7()
6568 spec->gen.preferred_dacs = preferred_pairs; in alc285_fixup_thinkpad_x1_gen7()
6591 strcpy(codec->card->longname, "HDAudio-Lenovo-DualCodecs"); in alc233_alc662_fixup_lenovo_dual_codecs()
6596 codec->addr == 0 ? in alc233_alc662_fixup_lenovo_dual_codecs()
6597 "Rear-Panel Capture Volume" : in alc233_alc662_fixup_lenovo_dual_codecs()
6598 "Front-Panel Capture Volume"); in alc233_alc662_fixup_lenovo_dual_codecs()
6600 codec->addr == 0 ? in alc233_alc662_fixup_lenovo_dual_codecs()
6601 "Rear-Panel Capture Switch" : in alc233_alc662_fixup_lenovo_dual_codecs()
6602 "Front-Panel Capture Switch"); in alc233_alc662_fixup_lenovo_dual_codecs()
6613 codec->power_save_node = 1; in alc225_fixup_s3_pop_noise()
6620 struct alc_spec *spec = codec->spec; in alc274_fixup_bind_dacs()
6629 spec->gen.preferred_dacs = preferred_pairs; in alc274_fixup_bind_dacs()
6630 spec->gen.auto_mute_via_amp = 1; in alc274_fixup_bind_dacs()
6631 codec->power_save_node = 0; in alc274_fixup_bind_dacs()
6641 struct alc_spec *spec = codec->spec; in alc289_fixup_asus_ga401()
6644 spec->gen.preferred_dacs = preferred_pairs; in alc289_fixup_asus_ga401()
6659 switch (codec->core.vendor_id) { in alc_combo_jack_hp_jd_restart()
6684 struct alc_spec *spec = codec->spec; in alc295_fixup_chromebook()
6688 spec->ultra_low_power = true; in alc295_fixup_chromebook()
6699 struct alc_spec *spec = codec->spec; in alc256_fixup_chromebook()
6703 spec->gen.suppress_auto_mute = 1; in alc256_fixup_chromebook()
6704 spec->gen.suppress_auto_mic = 1; in alc256_fixup_chromebook()
6705 spec->en_3kpull_low = false; in alc256_fixup_chromebook()
6803 struct alc_spec *spec = codec->spec; in alc_fixup_no_int_mic()
6809 spec->no_internal_mic_pin = true; in alc_fixup_no_int_mic()
6825 struct alc_spec *spec = codec->spec; in alc285_fixup_hp_spectre_x360_eb1()
6837 spec->micmute_led_polarity = 1; in alc285_fixup_hp_spectre_x360_eb1()
6839 spec->gpio_mask |= 0x01; in alc285_fixup_hp_spectre_x360_eb1()
6840 spec->gpio_dir |= 0x01; in alc285_fixup_hp_spectre_x360_eb1()
6905 snd_hda_codec_amp_stereo(codec, 0x21, HDA_OUTPUT, 0, -1, 0); in alc285_fixup_hp_envy_x360()
6907 /* Auto-enable headset mic when plugged */ in alc285_fixup_hp_envy_x360()
6918 "B&O-Tuned Playback Volume"); in alc285_fixup_hp_envy_x360()
6942 struct alc_spec *spec = codec->spec; in alc287_fixup_legion_15imhg05_speakers()
6946 spec->gen.suppress_auto_mute = 1; in alc287_fixup_legion_15imhg05_speakers()
6954 struct alc_spec *spec = cdc->spec; in comp_acpi_device_notify()
6958 hda_component_acpi_device_notify(&spec->comps, handle, event, data); in comp_acpi_device_notify()
6964 struct alc_spec *spec = cdc->spec; in comp_bind()
6967 ret = hda_component_manager_bind(cdc, &spec->comps); in comp_bind()
6972 &spec->comps, in comp_bind()
6979 struct alc_spec *spec = cdc->spec; in comp_unbind()
6981 hda_component_manager_unbind_acpi_notifications(cdc, &spec->comps, comp_acpi_device_notify); in comp_unbind()
6982 hda_component_manager_unbind(cdc, &spec->comps); in comp_unbind()
6993 struct alc_spec *spec = cdc->spec; in comp_generic_playback_hook()
6995 hda_component_manager_playback_hook(&spec->comps, action); in comp_generic_playback_hook()
7001 struct alc_spec *spec = cdc->spec; in comp_generic_fixup()
7006 ret = hda_component_manager_init(cdc, &spec->comps, count, bus, hid, in comp_generic_fixup()
7011 spec->gen.pcm_playback_hook = comp_generic_playback_hook; in comp_generic_fixup()
7014 hda_component_manager_free(&spec->comps, &comp_master_ops); in comp_generic_fixup()
7028 } acpi_ids[] = {{ "CSC3554", "cs35l54-hda" }, in find_cirrus_companion_amps()
7029 { "CSC3556", "cs35l56-hda" }, in find_cirrus_companion_amps()
7030 { "CSC3557", "cs35l57-hda" }}; in find_cirrus_companion_amps()
7035 adev = acpi_dev_get_first_match_dev(acpi_ids[i].hid, NULL, -1); in find_cirrus_companion_amps()
7067 * When available the cirrus,dev-index property is an accurate in find_cirrus_companion_amps()
7072 count_devindex = fwnode_property_count_u32(fwnode, "cirrus,dev-index"); in find_cirrus_companion_amps()
7076 match = devm_kasprintf(dev, GFP_KERNEL, "-%%s:00-%s.%%d", acpi_ids[i].name); in find_cirrus_companion_amps()
7085 comp_generic_fixup(cdc, action, "i2c", "CSC3551", "-%s:00-cs35l41-hda.%d", 2); in cs35l41_fixup_i2c_two()
7090 comp_generic_fixup(cdc, action, "i2c", "CSC3551", "-%s:00-cs35l41-hda.%d", 4); in cs35l41_fixup_i2c_four()
7095 comp_generic_fixup(codec, action, "spi", "CSC3551", "-%s:00-cs35l41-hda.%d", 2); in cs35l41_fixup_spi_two()
7100 comp_generic_fixup(codec, action, "spi", "CSC3551", "-%s:00-cs35l41-hda.%d", 4); in cs35l41_fixup_spi_four()
7106 comp_generic_fixup(cdc, action, "i2c", "CLSA0100", "-%s:00-cs35l41-hda.%d", 2); in alc287_fixup_legion_16achg6_speakers()
7112 comp_generic_fixup(cdc, action, "i2c", "CLSA0101", "-%s:00-cs35l41-hda.%d", 2); in alc287_fixup_legion_16ithg6_speakers()
7118 * The same SSID has been re-used in different hardware, they have in alc285_fixup_asus_ga403u()
7121 if (cdc->core.vendor_id != 0x10ec0285) in alc285_fixup_asus_ga403u()
7128 comp_generic_fixup(cdc, action, "i2c", "TIAS2781", "-%s:00", 1); in tas2781_fixup_i2c()
7134 comp_generic_fixup(cdc, action, "i2c", "INT8866", "-%s:00", 1); in yoga7_14arb7_fixup_i2c()
7166 * plugged-in state, while the internal microphone is always in an in alc256_fixup_set_coef_defaults()
7202 if (codec->core.vendor_id == 0x10ec0256) { in alc256_fixup_mic_no_presence_and_resume()
7220 nsteps = ((caps & AC_AMPCAP_NUM_STEPS) >> AC_AMPCAP_NUM_STEPS_SHIFT) - 10; in alc256_decrease_headphone_amp_val()
7221 offs = ((caps & AC_AMPCAP_OFFSET) >> AC_AMPCAP_OFFSET_SHIFT) - 10; in alc256_decrease_headphone_amp_val()
7233 struct alc_spec *spec = codec->spec; in alc_fixup_dell4_mic_no_presence_quiet()
7234 struct hda_input_mux *imux = &spec->gen.input_mux; in alc_fixup_dell4_mic_no_presence_quiet()
7243 * to Hi-Z to avoid pop noises at startup and when plugging and in alc_fixup_dell4_mic_no_presence_quiet()
7254 for (i = 0; i < imux->num_items; i++) { in alc_fixup_dell4_mic_no_presence_quiet()
7255 if (spec->gen.imux_pins[i] == 0x12) { in alc_fixup_dell4_mic_no_presence_quiet()
7256 spec->gen.cur_mux[0] = i; in alc_fixup_dell4_mic_no_presence_quiet()
7290 struct alc_spec *spec = codec->spec; in alc287_fixup_yoga9_14iap7_bass_spk_pin()
7296 spec->gen.preferred_dacs = preferred_pairs; in alc287_fixup_yoga9_14iap7_bass_spk_pin()
7316 struct alc_spec *spec = codec->spec; in alc295_fixup_dell_inspiron_top_speakers()
7324 spec->gen.preferred_dacs = preferred_pairs; in alc295_fixup_dell_inspiron_top_speakers()
7333 struct alc_spec *spec = codec->spec; in alc287_fixup_bind_dacs()
7343 spec->gen.preferred_dacs = preferred_pairs; in alc287_fixup_bind_dacs()
7344 spec->gen.auto_mute_via_amp = 1; in alc287_fixup_bind_dacs()
7345 if (spec->gen.autocfg.speaker_pins[0] != 0x14) { in alc287_fixup_bind_dacs()
7354 struct alc_spec *spec = codec->spec; in alc_fixup_headset_mic()
7364 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc_fixup_headset_mic()
7411 struct alc_spec *spec = codec->spec; in alc245_fixup_hp_spectre_x360_16_aa0xxx()
7426 spec->gpio_mask |= 0x01; in alc245_fixup_hp_spectre_x360_16_aa0xxx()
7427 spec->gpio_dir |= 0x01; in alc245_fixup_hp_spectre_x360_16_aa0xxx()
7472 struct alc_spec *spec = codec->spec; in alc287_fixup_lenovo_thinkpad_with_alc1318()
7484 spec->power_hook = alc287_s4_power_gpio3_default; in alc287_fixup_lenovo_thinkpad_with_alc1318()
7485 spec->gen.pcm_playback_hook = alc287_alc1318_playback_pcm_hook; in alc287_fixup_lenovo_thinkpad_with_alc1318()
7800 if (codec->core.vendor_id == 0x10ec0298) in alc298_fixup_lenovo_c940_duet7()
7912 { 0x1a, 0x2101103f }, /* dock line-out */
7913 { 0x1b, 0x23a11040 }, /* dock mic-in */
7974 { 0x19, 0x99a3092f }, /* int-mic */
7981 { 0x12, 0x99a3092f }, /* int-mic */
7993 { 0x19, 0x99a3092f }, /* int-mic */
8001 { 0x12, 0x99a3092f }, /* int-mic */
8195 { 0x1b, 0x99a7012f }, /* int-mic */
8215 { 0x12, 0x99a3092f }, /* int-mic */
8240 /* class-D output amp +5dB */
8266 { 0x12, 0x99a3092f }, /* int-mic */
8457 { 0x1b, 0x21011020 }, /* line-out */
8459 { 0x18, 0x2181103f }, /* line-in */
8468 { 0x1b, 0x21011020 }, /* line-out */
8469 { 0x18, 0x2181103f }, /* line-in */
8612 /* Disable pass-through path for FRONT 14h */
8968 /* Disable PCBEEP-IN passthrough */
9187 /* set 0x15 to HP-OUT ctrl */
9214 /* set 0x15 to HP-OUT ctrl */
9218 /* set 0x1b to HP-OUT */
10127 SND_PCI_QUIRK(0x1025, 0x072d, "Acer Aspire V5-571G", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
10130 SND_PCI_QUIRK(0x1025, 0x0762, "Acer Aspire E1-472", ALC271_FIXUP_HP_GATE_MIC_JACK_E1_572),
10131 SND_PCI_QUIRK(0x1025, 0x0775, "Acer Aspire E1-572", ALC271_FIXUP_HP_GATE_MIC_JACK_E1_572),
10132 SND_PCI_QUIRK(0x1025, 0x079b, "Acer Aspire V5-573G", ALC282_FIXUP_ASPIRE_V5_PINS),
10133 SND_PCI_QUIRK(0x1025, 0x080d, "Acer Aspire V5-122P", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
10135 SND_PCI_QUIRK(0x1025, 0x100c, "Acer Aspire E5-574G", ALC255_FIXUP_ACER_LIMIT_INT_MIC_BOOST),
10137 SND_PCI_QUIRK(0x1025, 0x102b, "Acer Aspire C24-860", ALC286_FIXUP_ACER_AIO_MIC_NO_PRESENCE),
10138 SND_PCI_QUIRK(0x1025, 0x1065, "Acer Aspire C20-820", ALC269VC_FIXUP_ACER_HEADSET_MIC),
10140 SND_PCI_QUIRK(0x1025, 0x1094, "Acer Aspire E5-575T", ALC255_FIXUP_ACER_LIMIT_INT_MIC_BOOST),
10141 SND_PCI_QUIRK(0x1025, 0x1099, "Acer Aspire E5-523G", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
10142 SND_PCI_QUIRK(0x1025, 0x110e, "Acer Aspire ES1-432", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
10145 SND_PCI_QUIRK(0x1025, 0x1177, "Acer Predator G9-593", ALC255_FIXUP_PREDATOR_SUBWOOFER),
10146 SND_PCI_QUIRK(0x1025, 0x1178, "Acer Predator G9-593", ALC255_FIXUP_PREDATOR_SUBWOOFER),
10150 SND_PCI_QUIRK(0x1025, 0x1269, "Acer SWIFT SF314-54", ALC256_FIXUP_ACER_HEADSET_MIC),
10151 SND_PCI_QUIRK(0x1025, 0x126a, "Acer Swift SF114-32", ALC256_FIXUP_ACER_MIC_NO_PRESENCE),
10155 SND_PCI_QUIRK(0x1025, 0x129c, "Acer SWIFT SF314-55", ALC256_FIXUP_ACER_HEADSET_MIC),
10156 SND_PCI_QUIRK(0x1025, 0x129d, "Acer SWIFT SF313-51", ALC256_FIXUP_ACER_MIC_NO_PRESENCE),
10157 SND_PCI_QUIRK(0x1025, 0x1300, "Acer SWIFT SF314-56", ALC256_FIXUP_ACER_MIC_NO_PRESENCE),
10158 SND_PCI_QUIRK(0x1025, 0x1308, "Acer Aspire Z24-890", ALC286_FIXUP_ACER_AIO_HEADSET_MIC),
10159 SND_PCI_QUIRK(0x1025, 0x132a, "Acer TravelMate B114-21", ALC233_FIXUP_ACER_HEADSET_MIC),
10160 SND_PCI_QUIRK(0x1025, 0x1330, "Acer TravelMate X514-51T", ALC255_FIXUP_ACER_HEADSET_MIC),
10161 SND_PCI_QUIRK(0x1025, 0x141f, "Acer Spin SP513-54N", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
10162 SND_PCI_QUIRK(0x1025, 0x142b, "Acer Swift SF314-42", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
10163 SND_PCI_QUIRK(0x1025, 0x1430, "Acer TravelMate B311R-31", ALC256_FIXUP_ACER_MIC_NO_PRESENCE),
10164 SND_PCI_QUIRK(0x1025, 0x1466, "Acer Aspire A515-56", ALC255_FIXUP_ACER_HEADPHONE_AND_MIC),
10165 SND_PCI_QUIRK(0x1025, 0x1534, "Acer Predator PH315-54", ALC255_FIXUP_ACER_MIC_NO_PRESENCE),
10166 SND_PCI_QUIRK(0x1025, 0x159c, "Acer Nitro 5 AN515-58", ALC2XX_FIXUP_HEADSET_MIC),
10229 …SND_PCI_QUIRK(0x1028, 0x0b37, "Dell Inspiron 16 Plus 7620 2-in-1", ALC295_FIXUP_DELL_INSPIRON_TOP_…
10233 SND_PCI_QUIRK(0x1028, 0x0c0b, "Dell Oasis 14 RPL-P", ALC289_FIXUP_RTK_AMP_DUAL_SPK),
10246 SND_PCI_QUIRK(0x1028, 0x0cbd, "Dell Oasis 13 CS MTL-U", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10247 SND_PCI_QUIRK(0x1028, 0x0cbe, "Dell Oasis 13 2-IN-1 MTL-U", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10248 SND_PCI_QUIRK(0x1028, 0x0cbf, "Dell Oasis 13 Low Weight MTU-L", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10250 SND_PCI_QUIRK(0x1028, 0x0cc1, "Dell Oasis 14 MTL-H/U", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10251 SND_PCI_QUIRK(0x1028, 0x0cc2, "Dell Oasis 14 2-in-1 MTL-H/U", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10252 SND_PCI_QUIRK(0x1028, 0x0cc3, "Dell Oasis 14 Low Weight MTL-U", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10253 SND_PCI_QUIRK(0x1028, 0x0cc4, "Dell Oasis 16 MTL-H/U", ALC289_FIXUP_DELL_CS35L41_SPI_2),
10326 SND_PCI_QUIRK(0x103c, 0x841c, "HP Pavilion 15-CK0xx", ALC269_FIXUP_HP_MUTE_LED_MIC3),
10329 SND_PCI_QUIRK(0x103c, 0x84ae, "HP 15-db0403ng", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10330 SND_PCI_QUIRK(0x103c, 0x84da, "HP OMEN dc0019-ur", ALC295_FIXUP_HP_OMEN),
10332 SND_PCI_QUIRK(0x103c, 0x8519, "HP Spectre x360 15-df0xxx", ALC285_FIXUP_HP_SPECTRE_X360),
10334 SND_PCI_QUIRK(0x103c, 0x85de, "HP Envy x360 13-ar0xxx", ALC285_FIXUP_HP_ENVY_X360),
10338 SND_PCI_QUIRK(0x103c, 0x86c1, "HP Laptop 15-da3001TU", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10340 SND_PCI_QUIRK(0x103c, 0x86e7, "HP Spectre x360 15-eb0xxx", ALC285_FIXUP_HP_SPECTRE_X360_EB1),
10341 SND_PCI_QUIRK(0x103c, 0x86e8, "HP Spectre x360 15-eb0xxx", ALC285_FIXUP_HP_SPECTRE_X360_EB1),
10342 SND_PCI_QUIRK(0x103c, 0x86f9, "HP Spectre x360 13-aw0xxx", ALC285_FIXUP_HP_SPECTRE_X360_MUTE_LED),
10352 …SND_PCI_QUIRK(0x103c, 0x876e, "HP ENVY x360 Convertible 13-ay0xxx", ALC245_FIXUP_HP_X360_MUTE_LEDS…
10362 SND_PCI_QUIRK(0x103c, 0x87b7, "HP Laptop 14-fq0xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10364 SND_PCI_QUIRK(0x103c, 0x87d3, "HP Laptop 15-gw0xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10374 SND_PCI_QUIRK(0x103c, 0x87fd, "HP Laptop 14-dq2xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10375 SND_PCI_QUIRK(0x103c, 0x87fe, "HP Laptop 15s-fq2xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10378 SND_PCI_QUIRK(0x103c, 0x8811, "HP Spectre x360 15-eb1xxx", ALC285_FIXUP_HP_SPECTRE_X360_EB1),
10379 SND_PCI_QUIRK(0x103c, 0x8812, "HP Spectre x360 15-eb1xxx", ALC285_FIXUP_HP_SPECTRE_X360_EB1),
10390 SND_PCI_QUIRK(0x103c, 0x887a, "HP Laptop 15s-eq2xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10391 …SND_PCI_QUIRK(0x103c, 0x888a, "HP ENVY x360 Convertible 15-eu0xxx", ALC245_FIXUP_HP_X360_MUTE_LEDS…
10396 SND_PCI_QUIRK(0x103c, 0x88d0, "HP Pavilion 15-eh1xxx (mainboard 88D0)", ALC287_FIXUP_HP_GPIO_LED),
10397 SND_PCI_QUIRK(0x103c, 0x88dd, "HP Pavilion 15z-ec200", ALC285_FIXUP_HP_MUTE_LED),
10400 SND_PCI_QUIRK(0x103c, 0x8919, "HP Pavilion Aero Laptop 13-be0xxx", ALC287_FIXUP_HP_GPIO_LED),
10427 SND_PCI_QUIRK(0x103c, 0x8a0f, "HP Pavilion 14-ec1xxx", ALC287_FIXUP_HP_GPIO_LED),
10428 SND_PCI_QUIRK(0x103c, 0x8a20, "HP Laptop 15s-fq5xxx", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
10429 SND_PCI_QUIRK(0x103c, 0x8a25, "HP Victus 16-d1xxx (MB 8A25)", ALC245_FIXUP_HP_MUTE_LED_COEFBIT),
10497 …SND_PCI_QUIRK(0x103c, 0x8c15, "HP Spectre x360 2-in-1 Laptop 14-eu0xxx", ALC245_FIXUP_HP_SPECTRE_X…
10498 …SND_PCI_QUIRK(0x103c, 0x8c16, "HP Spectre x360 2-in-1 Laptop 16-aa0xxx", ALC245_FIXUP_HP_SPECTRE_X…
10500 SND_PCI_QUIRK(0x103c, 0x8c21, "HP Pavilion Plus Laptop 14-ey0XXX", ALC245_FIXUP_HP_X360_MUTE_LEDS),
10501 SND_PCI_QUIRK(0x103c, 0x8c30, "HP Victus 15-fb1xxx", ALC245_FIXUP_HP_MUTE_LED_COEFBIT),
10505 …SND_PCI_QUIRK(0x103c, 0x8c49, "HP Elite x360 830 2-in-1 G11", ALC245_FIXUP_CS35L41_SPI_2_HP_GPIO_L…
10512 SND_PCI_QUIRK(0x103c, 0x8c53, "HP Elite x360 1040 2-in-1 G11", ALC285_FIXUP_HP_GPIO_LED),
10541 SND_PCI_QUIRK(0x103c, 0x8cbd, "HP Pavilion Aero Laptop 13-bg0xxx", ALC245_FIXUP_HP_X360_MUTE_LEDS),
10688 SND_PCI_QUIRK(0x10ec, 0x11bc, "VAIO VJFE-IL", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
10695 SND_PCI_QUIRK(0x10f7, 0x8338, "Panasonic CF-SZ6", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
10697 SND_PCI_QUIRK(0x144d, 0xc169, "Samsung Notebook 9 Pen (NP930SBE-K01US)", ALC298_FIXUP_SAMSUNG_AMP),
10698 SND_PCI_QUIRK(0x144d, 0xc176, "Samsung Notebook 9 Pro (NP930MBE-K04US)", ALC298_FIXUP_SAMSUNG_AMP),
10699 …SND_PCI_QUIRK(0x144d, 0xc189, "Samsung Galaxy Flex Book (NT950QCG-X716)", ALC298_FIXUP_SAMSUNG_AMP…
10700 …SND_PCI_QUIRK(0x144d, 0xc18a, "Samsung Galaxy Book Ion (NP930XCJ-K01US)", ALC298_FIXUP_SAMSUNG_AMP…
10701 …SND_PCI_QUIRK(0x144d, 0xc1a3, "Samsung Galaxy Book Pro (NP935XDB-KC1SE)", ALC298_FIXUP_SAMSUNG_AMP…
10705 SND_PCI_QUIRK(0x144d, 0xc812, "Samsung Notebook Pen S (NT950SBE-X58)", ALC298_FIXUP_SAMSUNG_AMP),
10706 …SND_PCI_QUIRK(0x144d, 0xc830, "Samsung Galaxy Book Ion (NT950XCJ-X716A)", ALC298_FIXUP_SAMSUNG_AMP…
10716 SND_PCI_QUIRK(0x1458, 0xfa53, "Gigabyte BXBT-2807", ALC283_FIXUP_HEADSET_MIC),
10717 SND_PCI_QUIRK(0x1462, 0xb120, "MSI Cubi MS-B120", ALC283_FIXUP_HEADSET_MIC),
10718 SND_PCI_QUIRK(0x1462, 0xb171, "Cubi N 8GL (MS-B171)", ALC283_FIXUP_HEADSET_MIC),
10720 SND_PCI_QUIRK(0x152d, 0x1262, "Huawei NBLB-WAX9N", ALC2XX_FIXUP_HEADSET_MIC),
10762 SND_PCI_QUIRK(0x1558, 0x70f6, "Clevo NH77DPQ-Y", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
10772 …SND_PCI_QUIRK(0x1558, 0x8550, "Clevo NH[57][0-9][ER][ACDH]Q", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENC…
10773 …SND_PCI_QUIRK(0x1558, 0x8551, "Clevo NH[57][0-9][ER][ACDH]Q", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENC…
10774 SND_PCI_QUIRK(0x1558, 0x8560, "Clevo NH[57][0-9][ER][ACDH]Q", ALC269_FIXUP_HEADSET_MIC),
10775 SND_PCI_QUIRK(0x1558, 0x8561, "Clevo NH[57][0-9][ER][ACDH]Q", ALC269_FIXUP_HEADSET_MIC),
10776 SND_PCI_QUIRK(0x1558, 0x8562, "Clevo NH[57][0-9]RZ[Q]", ALC269_FIXUP_DMIC),
10783 SND_PCI_QUIRK(0x1558, 0x8a20, "Clevo NH55DCQ-Y", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
10784 SND_PCI_QUIRK(0x1558, 0x8a51, "Clevo NH70RCQ-Y", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
10785 SND_PCI_QUIRK(0x1558, 0x8d50, "Clevo NH55RCQ-M", ALC293_FIXUP_SYSTEM76_MIC_NO_PRESENCE),
10830 SND_PCI_QUIRK(0x17aa, 0x2234, "Thinkpad ICE-1", ALC287_FIXUP_TAS2781_I2C),
10872 HDA_CODEC_QUIRK(0x17aa, 0x3820, "IdeaPad 330-17IKB 81DM", ALC269_FIXUP_ASPIRE_HEADSET_MIC),
10894 SND_PCI_QUIRK(0x17aa, 0x387d, "Yoga S780-16 pro Quad AAC", ALC287_FIXUP_TAS2781_I2C),
10895 SND_PCI_QUIRK(0x17aa, 0x387e, "Yoga S780-16 pro Quad YC", ALC287_FIXUP_TAS2781_I2C),
10896 SND_PCI_QUIRK(0x17aa, 0x387f, "Yoga S780-16 pro dual LX", ALC287_FIXUP_TAS2781_I2C),
10897 SND_PCI_QUIRK(0x17aa, 0x3880, "Yoga S780-16 pro dual YC", ALC287_FIXUP_TAS2781_I2C),
10912 SND_PCI_QUIRK(0x17aa, 0x38b8, "Yoga S780-14.5 proX AMD YC Dual", ALC287_FIXUP_TAS2781_I2C),
10913 SND_PCI_QUIRK(0x17aa, 0x38b9, "Yoga S780-14.5 proX AMD LX Dual", ALC287_FIXUP_TAS2781_I2C),
10914 SND_PCI_QUIRK(0x17aa, 0x38ba, "Yoga S780-14.5 Air AMD quad YC", ALC287_FIXUP_TAS2781_I2C),
10915 SND_PCI_QUIRK(0x17aa, 0x38bb, "Yoga S780-14.5 Air AMD quad AAC", ALC287_FIXUP_TAS2781_I2C),
10916 SND_PCI_QUIRK(0x17aa, 0x38be, "Yoga S980-14.5 proX YC Dual", ALC287_FIXUP_TAS2781_I2C),
10917 SND_PCI_QUIRK(0x17aa, 0x38bf, "Yoga S980-14.5 proX LX Dual", ALC287_FIXUP_TAS2781_I2C),
10924 SND_PCI_QUIRK(0x17aa, 0x38d3, "Yoga S990-16 Pro IMH YC Dual", ALC287_FIXUP_TAS2781_I2C),
10925 SND_PCI_QUIRK(0x17aa, 0x38d4, "Yoga S990-16 Pro IMH VECO Dual", ALC287_FIXUP_TAS2781_I2C),
10926 SND_PCI_QUIRK(0x17aa, 0x38d5, "Yoga S990-16 Pro IMH YC Quad", ALC287_FIXUP_TAS2781_I2C),
10927 SND_PCI_QUIRK(0x17aa, 0x38d6, "Yoga S990-16 Pro IMH VECO Quad", ALC287_FIXUP_TAS2781_I2C),
10936 SND_PCI_QUIRK(0x17aa, 0x3902, "Lenovo E50-80", ALC269_FIXUP_DMIC_THINKPAD_ACPI),
10938 SND_PCI_QUIRK(0x17aa, 0x391f, "Yoga S990-16 pro Quad YC Quad", ALC287_FIXUP_TAS2781_I2C),
10939 SND_PCI_QUIRK(0x17aa, 0x3920, "Yoga S990-16 pro Quad VECO Quad", ALC287_FIXUP_TAS2781_I2C),
10941 SND_PCI_QUIRK(0x17aa, 0x3978, "Lenovo B50-70", ALC269_FIXUP_DMIC_THINKPAD_ACPI),
10970 SND_PCI_QUIRK(0x19e5, 0x3204, "Huawei MACH-WX9", ALC256_FIXUP_HUAWEI_MACH_WX9_PINS),
10971 SND_PCI_QUIRK(0x19e5, 0x320f, "Huawei WRT-WX9 ", ALC256_FIXUP_ASUS_MIC_NO_PRESENCE),
10972 SND_PCI_QUIRK(0x19e5, 0x3212, "Huawei KLV-WX9 ", ALC256_FIXUP_ACER_HEADSET_MIC),
10976 …b7d, 0xa831, "Ordissimo EVE2 ", ALC269VB_FIXUP_ORDISSIMO_EVE2), /* Also known as Malata PC-B1303 */
10980 SND_PCI_QUIRK(0x1c6c, 0x1251, "Positivo N14KP6-TG", ALC288_FIXUP_DELL1_MIC_NO_PRESENCE),
10998 SND_PCI_QUIRK(0x2782, 0x0214, "VAIO VJFE-CL", ALC269_FIXUP_LIMIT_INT_MIC_BOOST),
11003 SND_PCI_QUIRK(0x2782, 0x1707, "Vaio VJFE-ADL", ALC298_FIXUP_SPK_VOLUME),
11075 {.id = ALC269_FIXUP_AMIC, .name = "laptop-amic"},
11076 {.id = ALC269_FIXUP_DMIC, .name = "laptop-dmic"},
11077 {.id = ALC269_FIXUP_STEREO_DMIC, .name = "alc269-dmic"},
11078 {.id = ALC271_FIXUP_DMIC, .name = "alc271-dmic"},
11079 {.id = ALC269_FIXUP_INV_DMIC, .name = "inv-dmic"},
11080 {.id = ALC269_FIXUP_HEADSET_MIC, .name = "headset-mic"},
11081 {.id = ALC269_FIXUP_HEADSET_MODE, .name = "headset-mode"},
11082 {.id = ALC269_FIXUP_HEADSET_MODE_NO_HP_MIC, .name = "headset-mode-no-hp-mic"},
11083 {.id = ALC269_FIXUP_LENOVO_DOCK, .name = "lenovo-dock"},
11084 {.id = ALC269_FIXUP_LENOVO_DOCK_LIMIT_BOOST, .name = "lenovo-dock-limit-boost"},
11085 {.id = ALC269_FIXUP_HP_GPIO_LED, .name = "hp-gpio-led"},
11086 {.id = ALC269_FIXUP_HP_DOCK_GPIO_MIC1_LED, .name = "hp-dock-gpio-mic1-led"},
11087 {.id = ALC269_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "dell-headset-multi"},
11088 {.id = ALC269_FIXUP_DELL2_MIC_NO_PRESENCE, .name = "dell-headset-dock"},
11089 {.id = ALC269_FIXUP_DELL3_MIC_NO_PRESENCE, .name = "dell-headset3"},
11090 {.id = ALC269_FIXUP_DELL4_MIC_NO_PRESENCE, .name = "dell-headset4"},
11091 {.id = ALC269_FIXUP_DELL4_MIC_NO_PRESENCE_QUIET, .name = "dell-headset4-quiet"},
11092 {.id = ALC283_FIXUP_CHROME_BOOK, .name = "alc283-dac-wcaps"},
11093 {.id = ALC283_FIXUP_SENSE_COMBO_JACK, .name = "alc283-sense-combo"},
11094 {.id = ALC292_FIXUP_TPT440_DOCK, .name = "tpt440-dock"},
11097 {.id = ALC298_FIXUP_TPT470_DOCK_FIX, .name = "tpt470-dock-fix"},
11098 {.id = ALC298_FIXUP_TPT470_DOCK, .name = "tpt470-dock"},
11099 {.id = ALC233_FIXUP_LENOVO_MULTI_CODECS, .name = "dual-codecs"},
11100 {.id = ALC700_FIXUP_INTEL_REFERENCE, .name = "alc700-ref"},
11102 {.id = ALC269_FIXUP_DELL_M101Z, .name = "dell-m101z"},
11103 {.id = ALC269_FIXUP_ASUS_G73JW, .name = "asus-g73jw"},
11104 {.id = ALC269_FIXUP_LENOVO_EAPD, .name = "lenovo-eapd"},
11105 {.id = ALC275_FIXUP_SONY_HWEQ, .name = "sony-hweq"},
11108 {.id = ALC269_FIXUP_LIFEBOOK_EXTMIC, .name = "lifebook-extmic"},
11109 {.id = ALC269_FIXUP_LIFEBOOK_HP_PIN, .name = "lifebook-hp-pin"},
11110 {.id = ALC255_FIXUP_LIFEBOOK_U7x7_HEADSET_MIC, .name = "lifebook-u7x7"},
11111 {.id = ALC269VB_FIXUP_AMIC, .name = "alc269vb-amic"},
11112 {.id = ALC269VB_FIXUP_DMIC, .name = "alc269vb-dmic"},
11113 {.id = ALC269_FIXUP_HP_MUTE_LED_MIC1, .name = "hp-mute-led-mic1"},
11114 {.id = ALC269_FIXUP_HP_MUTE_LED_MIC2, .name = "hp-mute-led-mic2"},
11115 {.id = ALC269_FIXUP_HP_MUTE_LED_MIC3, .name = "hp-mute-led-mic3"},
11116 {.id = ALC269_FIXUP_HP_GPIO_MIC1_LED, .name = "hp-gpio-mic1"},
11117 {.id = ALC269_FIXUP_HP_LINE1_MIC1_LED, .name = "hp-line1-mic1"},
11119 {.id = ALC286_FIXUP_SONY_MIC_NO_PRESENCE, .name = "sony-nomic"},
11120 {.id = ALC269_FIXUP_ASPIRE_HEADSET_MIC, .name = "aspire-headset-mic"},
11121 {.id = ALC269_FIXUP_ASUS_X101, .name = "asus-x101"},
11122 {.id = ALC271_FIXUP_HP_GATE_MIC_JACK, .name = "acer-ao7xx"},
11123 {.id = ALC271_FIXUP_HP_GATE_MIC_JACK_E1_572, .name = "acer-aspire-e1"},
11124 {.id = ALC269_FIXUP_ACER_AC700, .name = "acer-ac700"},
11125 {.id = ALC269_FIXUP_LIMIT_INT_MIC_BOOST, .name = "limit-mic-boost"},
11126 {.id = ALC269VB_FIXUP_ASUS_ZENBOOK, .name = "asus-zenbook"},
11127 {.id = ALC269VB_FIXUP_ASUS_ZENBOOK_UX31A, .name = "asus-zenbook-ux31a"},
11129 {.id = ALC282_FIXUP_ASUS_TX300, .name = "asus-tx300"},
11130 {.id = ALC283_FIXUP_INT_MIC, .name = "alc283-int-mic"},
11131 {.id = ALC290_FIXUP_MONO_SPEAKERS_HSJACK, .name = "mono-speakers"},
11132 {.id = ALC290_FIXUP_SUBWOOFER_HSJACK, .name = "alc290-subwoofer"},
11134 {.id = ALC269_FIXUP_DMIC_THINKPAD_ACPI, .name = "dmic-thinkpad"},
11135 {.id = ALC255_FIXUP_ACER_MIC_NO_PRESENCE, .name = "alc255-acer"},
11136 {.id = ALC255_FIXUP_ASUS_MIC_NO_PRESENCE, .name = "alc255-asus"},
11137 {.id = ALC255_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc255-dell1"},
11138 {.id = ALC255_FIXUP_DELL2_MIC_NO_PRESENCE, .name = "alc255-dell2"},
11139 {.id = ALC293_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc293-dell1"},
11140 {.id = ALC283_FIXUP_HEADSET_MIC, .name = "alc283-headset"},
11141 {.id = ALC255_FIXUP_MIC_MUTE_LED, .name = "alc255-dell-mute"},
11142 {.id = ALC282_FIXUP_ASPIRE_V5_PINS, .name = "aspire-v5"},
11143 {.id = ALC269VB_FIXUP_ASPIRE_E1_COEF, .name = "aspire-e1-coef"},
11144 {.id = ALC280_FIXUP_HP_GPIO4, .name = "hp-gpio4"},
11145 {.id = ALC286_FIXUP_HP_GPIO_LED, .name = "hp-gpio-led"},
11146 {.id = ALC280_FIXUP_HP_GPIO2_MIC_HOTKEY, .name = "hp-gpio2-hotkey"},
11147 {.id = ALC280_FIXUP_HP_DOCK_PINS, .name = "hp-dock-pins"},
11148 {.id = ALC269_FIXUP_HP_DOCK_GPIO_MIC1_LED, .name = "hp-dock-gpio-mic"},
11149 {.id = ALC280_FIXUP_HP_9480M, .name = "hp-9480m"},
11150 {.id = ALC288_FIXUP_DELL_HEADSET_MODE, .name = "alc288-dell-headset"},
11151 {.id = ALC288_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc288-dell1"},
11152 {.id = ALC288_FIXUP_DELL_XPS_13, .name = "alc288-dell-xps13"},
11153 {.id = ALC292_FIXUP_DELL_E7X, .name = "dell-e7x"},
11154 {.id = ALC293_FIXUP_DISABLE_AAMIX_MULTIJACK, .name = "alc293-dell"},
11155 {.id = ALC298_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc298-dell1"},
11156 {.id = ALC298_FIXUP_DELL_AIO_MIC_NO_PRESENCE, .name = "alc298-dell-aio"},
11157 {.id = ALC275_FIXUP_DELL_XPS, .name = "alc275-dell-xps"},
11158 {.id = ALC293_FIXUP_LENOVO_SPK_NOISE, .name = "lenovo-spk-noise"},
11159 {.id = ALC233_FIXUP_LENOVO_LINE2_MIC_HOTKEY, .name = "lenovo-hotkey"},
11160 {.id = ALC255_FIXUP_DELL_SPK_NOISE, .name = "dell-spk-noise"},
11161 {.id = ALC225_FIXUP_DELL1_MIC_NO_PRESENCE, .name = "alc225-dell1"},
11162 {.id = ALC295_FIXUP_DISABLE_DAC3, .name = "alc295-disable-dac3"},
11163 {.id = ALC285_FIXUP_SPEAKER2_TO_DAC1, .name = "alc285-speaker2-to-dac1"},
11164 {.id = ALC280_FIXUP_HP_HEADSET_MIC, .name = "alc280-hp-headset"},
11165 {.id = ALC221_FIXUP_HP_FRONT_MIC, .name = "alc221-hp-mic"},
11166 {.id = ALC298_FIXUP_SPK_VOLUME, .name = "alc298-spk-volume"},
11167 {.id = ALC256_FIXUP_DELL_INSPIRON_7559_SUBWOOFER, .name = "dell-inspiron-7559"},
11168 {.id = ALC269_FIXUP_ATIV_BOOK_8, .name = "ativ-book"},
11169 {.id = ALC221_FIXUP_HP_MIC_NO_PRESENCE, .name = "alc221-hp-mic"},
11170 {.id = ALC256_FIXUP_ASUS_HEADSET_MODE, .name = "alc256-asus-headset"},
11171 {.id = ALC256_FIXUP_ASUS_MIC, .name = "alc256-asus-mic"},
11172 {.id = ALC256_FIXUP_ASUS_AIO_GPIO2, .name = "alc256-asus-aio"},
11173 {.id = ALC233_FIXUP_ASUS_MIC_NO_PRESENCE, .name = "alc233-asus"},
11174 {.id = ALC233_FIXUP_EAPD_COEF_AND_MIC_NO_PRESENCE, .name = "alc233-eapd"},
11175 {.id = ALC294_FIXUP_LENOVO_MIC_LOCATION, .name = "alc294-lenovo-mic"},
11176 {.id = ALC225_FIXUP_DELL_WYSE_MIC_NO_PRESENCE, .name = "alc225-wyse"},
11177 {.id = ALC274_FIXUP_DELL_AIO_LINEOUT_VERB, .name = "alc274-dell-aio"},
11178 {.id = ALC255_FIXUP_DUMMY_LINEOUT_VERB, .name = "alc255-dummy-lineout"},
11179 {.id = ALC255_FIXUP_DELL_HEADSET_MIC, .name = "alc255-dell-headset"},
11180 {.id = ALC295_FIXUP_HP_X360, .name = "alc295-hp-x360"},
11181 {.id = ALC225_FIXUP_HEADSET_JACK, .name = "alc-headset-jack"},
11182 {.id = ALC295_FIXUP_CHROME_BOOK, .name = "alc-chrome-book"},
11183 {.id = ALC256_FIXUP_CHROME_BOOK, .name = "alc-2024y-chromebook"},
11184 {.id = ALC299_FIXUP_PREDATOR_SPK, .name = "predator-spk"},
11185 {.id = ALC298_FIXUP_HUAWEI_MBX_STEREO, .name = "huawei-mbx-stereo"},
11186 {.id = ALC256_FIXUP_MEDION_HEADSET_NO_PRESENCE, .name = "alc256-medion-headset"},
11187 {.id = ALC298_FIXUP_SAMSUNG_AMP, .name = "alc298-samsung-amp"},
11188 {.id = ALC298_FIXUP_SAMSUNG_AMP_V2_2_AMPS, .name = "alc298-samsung-amp-v2-2-amps"},
11189 {.id = ALC298_FIXUP_SAMSUNG_AMP_V2_4_AMPS, .name = "alc298-samsung-amp-v2-4-amps"},
11190 {.id = ALC256_FIXUP_SAMSUNG_HEADPHONE_VERY_QUIET, .name = "alc256-samsung-headphone"},
11191 {.id = ALC255_FIXUP_XIAOMI_HEADSET_MIC, .name = "alc255-xiaomi-headset"},
11192 {.id = ALC274_FIXUP_HP_MIC, .name = "alc274-hp-mic-detect"},
11193 {.id = ALC245_FIXUP_HP_X360_AMP, .name = "alc245-hp-x360-amp"},
11194 {.id = ALC295_FIXUP_HP_OMEN, .name = "alc295-hp-omen"},
11195 {.id = ALC285_FIXUP_HP_SPECTRE_X360, .name = "alc285-hp-spectre-x360"},
11196 {.id = ALC285_FIXUP_HP_SPECTRE_X360_EB1, .name = "alc285-hp-spectre-x360-eb1"},
11197 {.id = ALC285_FIXUP_HP_ENVY_X360, .name = "alc285-hp-envy-x360"},
11198 {.id = ALC287_FIXUP_IDEAPAD_BASS_SPK_AMP, .name = "alc287-ideapad-bass-spk-amp"},
11199 {.id = ALC287_FIXUP_YOGA9_14IAP7_BASS_SPK_PIN, .name = "alc287-yoga9-bass-spk-pin"},
11200 {.id = ALC623_FIXUP_LENOVO_THINKSTATION_P340, .name = "alc623-lenovo-thinkstation-p340"},
11201 {.id = ALC255_FIXUP_ACER_HEADPHONE_AND_MIC, .name = "alc255-acer-headphone-and-mic"},
11202 {.id = ALC285_FIXUP_HP_GPIO_AMP_INIT, .name = "alc285-hp-amp-init"},
11203 {.id = ALC236_FIXUP_LENOVO_INV_DMIC, .name = "alc236-fixup-lenovo-inv-mic"},
11204 {.id = ALC2XX_FIXUP_HEADSET_MIC, .name = "alc2xx-fixup-headset-mic"},
11668 struct alc_spec *spec = codec->spec; in alc269_fill_coef()
11671 if (spec->codec_variant != ALC269_TYPE_ALC269VB) in alc269_fill_coef()
11691 if (val != -1 && (val & 0x0c00) >> 10 != 0x1) { in alc269_fill_coef()
11696 if (val != -1 && (val & 0x01c0) >> 6 != 0x4) { in alc269_fill_coef()
11717 spec = codec->spec; in patch_alc269()
11718 spec->gen.shared_mic_vref_pin = 0x18; in patch_alc269()
11719 codec->power_save_node = 0; in patch_alc269()
11720 spec->en_3kpull_low = true; in patch_alc269()
11722 codec->patch_ops.suspend = alc269_suspend; in patch_alc269()
11723 codec->patch_ops.resume = alc269_resume; in patch_alc269()
11724 spec->shutup = alc_default_shutup; in patch_alc269()
11725 spec->init_hook = alc_default_init; in patch_alc269()
11727 switch (codec->core.vendor_id) { in patch_alc269()
11729 spec->codec_variant = ALC269_TYPE_ALC269VA; in patch_alc269()
11732 if (codec->bus->pci && in patch_alc269()
11733 codec->bus->pci->subsystem_vendor == 0x1025 && in patch_alc269()
11734 spec->cdefine.platform_type == 1) in patch_alc269()
11736 spec->codec_variant = ALC269_TYPE_ALC269VB; in patch_alc269()
11739 if (codec->bus->pci && in patch_alc269()
11740 codec->bus->pci->subsystem_vendor == 0x17aa && in patch_alc269()
11741 codec->bus->pci->subsystem_device == 0x21f3) in patch_alc269()
11743 spec->codec_variant = ALC269_TYPE_ALC269VC; in patch_alc269()
11746 spec->codec_variant = ALC269_TYPE_ALC269VD; in patch_alc269()
11753 spec->shutup = alc269_shutup; in patch_alc269()
11754 spec->init_hook = alc269_fill_coef; in patch_alc269()
11760 spec->codec_variant = ALC269_TYPE_ALC280; in patch_alc269()
11763 spec->codec_variant = ALC269_TYPE_ALC282; in patch_alc269()
11764 spec->shutup = alc282_shutup; in patch_alc269()
11765 spec->init_hook = alc282_init; in patch_alc269()
11769 spec->codec_variant = ALC269_TYPE_ALC283; in patch_alc269()
11770 spec->shutup = alc283_shutup; in patch_alc269()
11771 spec->init_hook = alc283_init; in patch_alc269()
11775 spec->codec_variant = ALC269_TYPE_ALC284; in patch_alc269()
11778 spec->codec_variant = ALC269_TYPE_ALC293; in patch_alc269()
11782 spec->codec_variant = ALC269_TYPE_ALC286; in patch_alc269()
11785 spec->codec_variant = ALC269_TYPE_ALC298; in patch_alc269()
11789 spec->codec_variant = ALC269_TYPE_ALC255; in patch_alc269()
11790 spec->shutup = alc256_shutup; in patch_alc269()
11791 spec->init_hook = alc256_init; in patch_alc269()
11797 spec->codec_variant = ALC269_TYPE_ALC256; in patch_alc269()
11798 spec->shutup = alc256_shutup; in patch_alc269()
11799 spec->init_hook = alc256_init; in patch_alc269()
11800 spec->gen.mixer_nid = 0; /* ALC256 does not have any loopback mixer path */ in patch_alc269()
11801 if (codec->core.vendor_id == 0x10ec0236 && in patch_alc269()
11802 codec->bus->pci->vendor != PCI_VENDOR_ID_AMD) in patch_alc269()
11803 spec->en_3kpull_low = false; in patch_alc269()
11806 spec->codec_variant = ALC269_TYPE_ALC257; in patch_alc269()
11807 spec->shutup = alc256_shutup; in patch_alc269()
11808 spec->init_hook = alc256_init; in patch_alc269()
11809 spec->gen.mixer_nid = 0; in patch_alc269()
11810 spec->en_3kpull_low = false; in patch_alc269()
11817 spec->codec_variant = ALC269_TYPE_ALC245; in patch_alc269()
11819 spec->codec_variant = ALC269_TYPE_ALC215; in patch_alc269()
11820 spec->shutup = alc225_shutup; in patch_alc269()
11821 spec->init_hook = alc225_init; in patch_alc269()
11822 spec->gen.mixer_nid = 0; in patch_alc269()
11827 spec->codec_variant = ALC269_TYPE_ALC225; in patch_alc269()
11828 spec->shutup = alc225_shutup; in patch_alc269()
11829 spec->init_hook = alc225_init; in patch_alc269()
11830 spec->gen.mixer_nid = 0; /* no loopback on ALC225, ALC295 and ALC299 */ in patch_alc269()
11833 spec->codec_variant = ALC269_TYPE_ALC287; in patch_alc269()
11834 spec->shutup = alc225_shutup; in patch_alc269()
11835 spec->init_hook = alc225_init; in patch_alc269()
11836 spec->gen.mixer_nid = 0; /* no loopback on ALC287 */ in patch_alc269()
11841 spec->codec_variant = ALC269_TYPE_ALC294; in patch_alc269()
11842 spec->gen.mixer_nid = 0; /* ALC2x4 does not have any loopback mixer path */ in patch_alc269()
11844 spec->init_hook = alc294_init; in patch_alc269()
11847 spec->codec_variant = ALC269_TYPE_ALC300; in patch_alc269()
11848 spec->gen.mixer_nid = 0; /* no loopback on ALC300 */ in patch_alc269()
11851 spec->codec_variant = ALC269_TYPE_ALC623; in patch_alc269()
11857 spec->codec_variant = ALC269_TYPE_ALC700; in patch_alc269()
11858 spec->gen.mixer_nid = 0; /* ALC700 does not have any loopback mixer path */ in patch_alc269()
11860 spec->init_hook = alc294_init; in patch_alc269()
11866 spec->has_alc5505_dsp = 1; in patch_alc269()
11867 spec->init_hook = alc5505_dsp_init; in patch_alc269()
11878 if (codec->fixup_id == ALC282_FIXUP_ASUS_TX300 && in patch_alc269()
11879 codec->core.vendor_id == 0x10ec0294) { in patch_alc269()
11881 codec->fixup_id = HDA_FIXUP_ID_NOT_SET; in patch_alc269()
11900 spec->gen.beep_nid = 0x01; in patch_alc269()
11907 if (!spec->gen.no_analog && spec->gen.beep_nid && spec->gen.mixer_nid) { in patch_alc269()
11908 err = set_beep_amp(spec, spec->gen.mixer_nid, 0x04, HDA_INPUT); in patch_alc269()
11946 struct alc_spec *spec = codec->spec; in alc861_fixup_asus_amp_vref_0f()
11956 spec->gen.keep_vref_in_automute = 1; in alc861_fixup_asus_amp_vref_0f()
11959 /* suppress the jack-detection */
11964 codec->no_jack_detect = 1; in alc_fixup_no_jack_detect()
12024 spec = codec->spec; in patch_alc861()
12026 spec->gen.beep_nid = 0x23; in patch_alc861()
12028 spec->power_hook = alc_power_eapd; in patch_alc861()
12040 if (!spec->gen.no_analog) { in patch_alc861()
12056 * ALC861-VD support
12088 struct alc_spec *spec = codec->spec; in alc660vd_fixup_asus_gpio1()
12091 spec->gpio_mask |= 0x02; in alc660vd_fixup_asus_gpio1()
12108 SND_PCI_QUIRK(0x1043, 0x1339, "ASUS A7-K", ALC660VD_FIX_ASUS_GPIO1),
12109 SND_PCI_QUIRK(0x1179, 0xff31, "Toshiba L30-149", ALC861VD_FIX_DALLAS),
12124 spec = codec->spec; in patch_alc861vd()
12126 spec->gen.beep_nid = 0x23; in patch_alc861vd()
12128 spec->shutup = alc_eapd_shutup; in patch_alc861vd()
12140 if (!spec->gen.no_analog) { in patch_alc861vd()
12161 * 6-channel independent captures.
12163 * In addition, an independent DAC for the multi-playback (not used in this
12178 if (codec->core.vendor_id == 0x10ec0272 || codec->core.vendor_id == 0x10ec0663 || in alc662_parse_auto_config()
12179 codec->core.vendor_id == 0x10ec0665 || codec->core.vendor_id == 0x10ec0670 || in alc662_parse_auto_config()
12180 codec->core.vendor_id == 0x10ec0671) in alc662_parse_auto_config()
12214 struct alc_spec *spec = codec->spec; in alc_fixup_bass_chmap()
12215 spec->gen.pcm_rec[0]->stream[0].chmap = asus_pcm_2_1_chmaps; in alc_fixup_bass_chmap()
12224 struct alc_spec *spec = codec->spec; in gpio_led_power_filter()
12225 if (nid == codec->core.afg && power_state == AC_PWRST_D3 && spec->gpio_data) in gpio_led_power_filter()
12233 struct alc_spec *spec = codec->spec; in alc662_fixup_led_gpio1()
12237 spec->mute_led_polarity = 1; in alc662_fixup_led_gpio1()
12238 codec->power_filter = gpio_led_power_filter; in alc662_fixup_led_gpio1()
12245 struct alc_spec *spec = codec->spec; in alc662_usi_automute_hook()
12250 vref = spec->gen.hp_jack_present ? PIN_VREF80 : 0; in alc662_usi_automute_hook()
12259 struct alc_spec *spec = codec->spec; in alc662_fixup_usi_headset_mic()
12261 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc662_fixup_usi_headset_mic()
12262 spec->gen.hp_automute_hook = alc662_usi_automute_hook; in alc662_fixup_usi_headset_mic()
12272 * 0x15 - front left/front right in alc662_aspire_ethos_mute_speakers()
12273 * 0x18 - front center/ LFE in alc662_aspire_ethos_mute_speakers()
12310 struct alc_spec *spec = codec->spec; in alc671_fixup_hp_headset_mic2()
12320 spec->gen.mixer_nid = 0; in alc671_fixup_hp_headset_mic2()
12321 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc671_fixup_hp_headset_mic2()
12333 struct alc_spec *spec = codec->spec; in alc897_hp_automute_hook()
12337 vref = spec->gen.hp_jack_present ? (PIN_HP | AC_PINCTL_VREF_100) : PIN_HP; in alc897_hp_automute_hook()
12344 struct alc_spec *spec = codec->spec; in alc897_fixup_lenovo_headset_mic()
12346 spec->gen.hp_automute_hook = alc897_hp_automute_hook; in alc897_fixup_lenovo_headset_mic()
12347 spec->no_shutup_pins = 1; in alc897_fixup_lenovo_headset_mic()
12357 struct alc_spec *spec = codec->spec; in alc897_fixup_lenovo_headset_mode()
12360 spec->parse_flags |= HDA_PINCFG_HEADSET_MIC; in alc897_fixup_lenovo_headset_mode()
12361 spec->gen.hp_automute_hook = alc897_hp_automute_hook; in alc897_fixup_lenovo_headset_mode()
12487 {0x19, 0x90a7013f}, /* int-mic */
12523 { 0x19, 0x99a3092f }, /* int-mic */
12535 { 0x19, 0x99a3092f }, /* int-mic */
12548 { 0x19, 0x99a3094f }, /* int-mic */
12561 { 0x19, 0x99a3094f }, /* int-mic */
12575 { 0x19, 0x99a3094f }, /* int-mic */
12587 { 0x19, 0x99a3094f }, /* int-mic */
12600 { 0x19, 0x99a3094f }, /* int-mic */
12612 { 0x12, 0x99a30970 }, /* int-mic */
12909 SND_PCI_QUIRK(0x1019, 0x9859, "JP-IK LEAP W502", ALC897_FIXUP_HEADSET_MIC_PIN3),
12918 SND_PCI_QUIRK(0x1025, 0x123c, "Acer Nitro N50-600", ALC662_FIXUP_ACER_NITRO_HEADSET_MODE),
12965 SND_PCI_QUIRK(0x17aa, 0x3742, "Lenovo TianYi510Pro-14IOB", ALC897_FIXUP_HEADSET_MIC_PIN2),
12973 SND_PCI_QUIRK(0x1c6c, 0x1239, "Compaq N14JP6-V2", ALC897_FIXUP_HP_HSMIC_VERB),
13039 {.id = ALC662_FIXUP_HP_RP5800, .name = "hp-rp5800"},
13040 {.id = ALC662_FIXUP_ASUS_MODE1, .name = "asus-mode1"},
13041 {.id = ALC662_FIXUP_ASUS_MODE2, .name = "asus-mode2"},
13042 {.id = ALC662_FIXUP_ASUS_MODE3, .name = "asus-mode3"},
13043 {.id = ALC662_FIXUP_ASUS_MODE4, .name = "asus-mode4"},
13044 {.id = ALC662_FIXUP_ASUS_MODE5, .name = "asus-mode5"},
13045 {.id = ALC662_FIXUP_ASUS_MODE6, .name = "asus-mode6"},
13046 {.id = ALC662_FIXUP_ASUS_MODE7, .name = "asus-mode7"},
13047 {.id = ALC662_FIXUP_ASUS_MODE8, .name = "asus-mode8"},
13048 {.id = ALC662_FIXUP_ZOTAC_Z68, .name = "zotac-z68"},
13049 {.id = ALC662_FIXUP_INV_DMIC, .name = "inv-dmic"},
13050 {.id = ALC662_FIXUP_DELL_MIC_NO_PRESENCE, .name = "alc662-headset-multi"},
13051 {.id = ALC668_FIXUP_DELL_MIC_NO_PRESENCE, .name = "dell-headset-multi"},
13052 {.id = ALC662_FIXUP_HEADSET_MODE, .name = "alc662-headset"},
13053 {.id = ALC668_FIXUP_HEADSET_MODE, .name = "alc668-headset"},
13057 {.id = ALC668_FIXUP_DELL_XPS13, .name = "dell-xps13"},
13058 {.id = ALC662_FIXUP_ASUS_Nx50, .name = "asus-nx50"},
13059 {.id = ALC668_FIXUP_ASUS_Nx51, .name = "asus-nx51"},
13060 {.id = ALC668_FIXUP_ASUS_G751, .name = "asus-g751"},
13061 {.id = ALC891_FIXUP_HEADSET_MODE, .name = "alc891-headset"},
13062 {.id = ALC891_FIXUP_DELL_MIC_NO_PRESENCE, .name = "alc891-headset-multi"},
13063 {.id = ALC662_FIXUP_ACER_VERITON, .name = "acer-veriton"},
13064 {.id = ALC892_FIXUP_ASROCK_MOBO, .name = "asrock-mobo"},
13065 {.id = ALC662_FIXUP_USI_HEADSET_MODE, .name = "usi-headset"},
13066 {.id = ALC662_FIXUP_LENOVO_MULTI_CODECS, .name = "dual-codecs"},
13067 {.id = ALC669_FIXUP_ACER_ASPIRE_ETHOS, .name = "aspire-ethos"},
13068 {.id = ALC897_FIXUP_UNIS_H3C_X500S, .name = "unis-h3c-x500s"},
13142 spec = codec->spec; in patch_alc662()
13144 spec->shutup = alc_eapd_shutup; in patch_alc662()
13147 spec->parse_flags = HDA_PINCFG_NO_HP_FIXUP; in patch_alc662()
13151 switch (codec->core.vendor_id) { in patch_alc662()
13153 spec->init_hook = alc668_restore_default_value; in patch_alc662()
13167 spec->gen.beep_nid = 0x01; in patch_alc662()
13170 codec->bus->pci && codec->bus->pci->subsystem_vendor == 0x1025 && in patch_alc662()
13171 spec->cdefine.platform_type == 1) { in patch_alc662()
13182 if (!spec->gen.no_analog && spec->gen.beep_nid) { in patch_alc662()
13183 switch (codec->core.vendor_id) { in patch_alc662()
13225 /* ALC680 has no aa-loopback mixer */ in patch_alc680()
13287 HDA_CODEC_ENTRY(0x10ec0660, "ALC660-VD", patch_alc861vd),
13289 HDA_CODEC_ENTRY(0x10ec0862, "ALC861-VD", patch_alc861vd),
13328 MODULE_DESCRIPTION("Realtek HD-audio codec");