Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ALSA: hda/realtek - Move ALC880 model=lg-lw to auto-parser

ALC880 model=lg-lw works fine with the auto-parser as is.

Signed-off-by: Takashi Iwai <tiwai@suse.de>

-103
-103
sound/pci/hda/alc880_quirks.c
··· 26 26 ALC880_CLEVO, 27 27 ALC880_TCL_S700, 28 28 ALC880_LG, 29 - ALC880_LG_LW, 30 29 #ifdef CONFIG_SND_DEBUG 31 30 ALC880_TEST, 32 31 #endif ··· 1050 1051 alc_simple_setup_automute(spec, ALC_AUTOMUTE_AMP); 1051 1052 } 1052 1053 1053 - /* 1054 - * LG LW20 1055 - * 1056 - * Pin assignment: 1057 - * Speaker-out: 0x14 1058 - * Mic-In: 0x18 1059 - * Built-in Mic-In: 0x19 1060 - * Line-In: 0x1b 1061 - * HP-Out: 0x1a 1062 - * SPDIF-Out: 0x1e 1063 - */ 1064 - 1065 - static const struct hda_input_mux alc880_lg_lw_capture_source = { 1066 - .num_items = 3, 1067 - .items = { 1068 - { "Mic", 0x0 }, 1069 - { "Internal Mic", 0x1 }, 1070 - { "Line In", 0x2 }, 1071 - }, 1072 - }; 1073 - 1074 - #define alc880_lg_lw_modes alc880_threestack_modes 1075 - 1076 - static const struct snd_kcontrol_new alc880_lg_lw_mixer[] = { 1077 - HDA_CODEC_VOLUME("Front Playback Volume", 0x0c, 0x0, HDA_OUTPUT), 1078 - HDA_BIND_MUTE("Front Playback Switch", 0x0c, 2, HDA_INPUT), 1079 - HDA_CODEC_VOLUME("Surround Playback Volume", 0x0f, 0x0, HDA_OUTPUT), 1080 - HDA_BIND_MUTE("Surround Playback Switch", 0x0f, 2, HDA_INPUT), 1081 - HDA_CODEC_VOLUME_MONO("Center Playback Volume", 0x0e, 1, 0x0, HDA_OUTPUT), 1082 - HDA_CODEC_VOLUME_MONO("LFE Playback Volume", 0x0e, 2, 0x0, HDA_OUTPUT), 1083 - HDA_BIND_MUTE_MONO("Center Playback Switch", 0x0e, 1, 2, HDA_INPUT), 1084 - HDA_BIND_MUTE_MONO("LFE Playback Switch", 0x0e, 2, 2, HDA_INPUT), 1085 - HDA_CODEC_VOLUME("Line Playback Volume", 0x0b, 0x02, HDA_INPUT), 1086 - HDA_CODEC_MUTE("Line Playback Switch", 0x0b, 0x02, HDA_INPUT), 1087 - HDA_CODEC_VOLUME("Mic Playback Volume", 0x0b, 0x0, HDA_INPUT), 1088 - HDA_CODEC_MUTE("Mic Playback Switch", 0x0b, 0x0, HDA_INPUT), 1089 - HDA_CODEC_VOLUME("Internal Mic Playback Volume", 0x0b, 0x01, HDA_INPUT), 1090 - HDA_CODEC_MUTE("Internal Mic Playback Switch", 0x0b, 0x01, HDA_INPUT), 1091 - { 1092 - .iface = SNDRV_CTL_ELEM_IFACE_MIXER, 1093 - .name = "Channel Mode", 1094 - .info = alc_ch_mode_info, 1095 - .get = alc_ch_mode_get, 1096 - .put = alc_ch_mode_put, 1097 - }, 1098 - { } /* end */ 1099 - }; 1100 - 1101 - static const struct hda_verb alc880_lg_lw_init_verbs[] = { 1102 - {0x13, AC_VERB_SET_CONNECT_SEL, 0x00}, /* HP */ 1103 - {0x10, AC_VERB_SET_CONNECT_SEL, 0x02}, /* mic/clfe */ 1104 - {0x12, AC_VERB_SET_CONNECT_SEL, 0x03}, /* line/surround */ 1105 - 1106 - /* set capture source to mic-in */ 1107 - {0x07, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)}, 1108 - {0x08, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)}, 1109 - {0x09, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)}, 1110 - {0x0b, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_MUTE(7)}, 1111 - /* speaker-out */ 1112 - {0x14, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_HP}, 1113 - {0x14, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE}, 1114 - /* HP-out */ 1115 - {0x1b, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_HP}, 1116 - {0x1b, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE}, 1117 - /* mic-in to input */ 1118 - {0x18, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_VREF80}, 1119 - {0x18, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE}, 1120 - /* built-in mic */ 1121 - {0x19, AC_VERB_SET_PIN_WIDGET_CONTROL, PIN_VREF80}, 1122 - {0x19, AC_VERB_SET_AMP_GAIN_MUTE, AMP_OUT_UNMUTE}, 1123 - /* jack sense */ 1124 - {0x1b, AC_VERB_SET_UNSOLICITED_ENABLE, AC_USRSP_EN | ALC_HP_EVENT}, 1125 - { } 1126 - }; 1127 - 1128 - /* toggle speaker-output according to the hp-jack state */ 1129 - static void alc880_lg_lw_setup(struct hda_codec *codec) 1130 - { 1131 - struct alc_spec *spec = codec->spec; 1132 - 1133 - spec->autocfg.hp_pins[0] = 0x1b; 1134 - spec->autocfg.speaker_pins[0] = 0x14; 1135 - alc_simple_setup_automute(spec, ALC_AUTOMUTE_AMP); 1136 - } 1137 - 1138 1054 #ifdef CONFIG_SND_HDA_POWER_SAVE 1139 1055 static const struct hda_amp_list alc880_lg_loopbacks[] = { 1140 1056 { 0x0b, HDA_INPUT, 1 }, ··· 1346 1432 [ALC880_FUJITSU] = "fujitsu", 1347 1433 [ALC880_F1734] = "F1734", 1348 1434 [ALC880_LG] = "lg", 1349 - [ALC880_LG_LW] = "lg-lw", 1350 1435 #ifdef CONFIG_SND_DEBUG 1351 1436 [ALC880_TEST] = "test", 1352 1437 #endif ··· 1402 1489 SND_PCI_QUIRK(0x1734, 0x1094, "FSC Amilo M1451G", ALC880_FUJITSU), 1403 1490 SND_PCI_QUIRK(0x1734, 0x10ac, "FSC AMILO Xi 1526", ALC880_F1734), 1404 1491 SND_PCI_QUIRK(0x1734, 0x10b0, "Fujitsu", ALC880_FUJITSU), 1405 - SND_PCI_QUIRK(0x1854, 0x0018, "LG LW20", ALC880_LG_LW), 1406 1492 SND_PCI_QUIRK(0x1854, 0x003b, "LG", ALC880_LG), 1407 1493 SND_PCI_QUIRK(0x1854, 0x005f, "LG P1 Express", ALC880_LG), 1408 1494 SND_PCI_QUIRK(0x1854, 0x0068, "LG w1", ALC880_LG), 1409 - SND_PCI_QUIRK(0x1854, 0x0077, "LG LW25", ALC880_LG_LW), 1410 1495 SND_PCI_QUIRK(0x19db, 0x4188, "TCL S700", ALC880_TCL_S700), 1411 1496 SND_PCI_QUIRK(0x2668, 0x8086, NULL, ALC880_6ST_DIG), /* broken BIOS */ 1412 1497 SND_PCI_QUIRK(0x8086, 0x2668, NULL, ALC880_6ST_DIG), ··· 1683 1772 #ifdef CONFIG_SND_HDA_POWER_SAVE 1684 1773 .loopbacks = alc880_lg_loopbacks, 1685 1774 #endif 1686 - }, 1687 - [ALC880_LG_LW] = { 1688 - .mixers = { alc880_lg_lw_mixer }, 1689 - .init_verbs = { alc880_volume_init_verbs, 1690 - alc880_lg_lw_init_verbs }, 1691 - .num_dacs = ARRAY_SIZE(alc880_dac_nids), 1692 - .dac_nids = alc880_dac_nids, 1693 - .dig_out_nid = ALC880_DIGOUT_NID, 1694 - .num_channel_mode = ARRAY_SIZE(alc880_lg_lw_modes), 1695 - .channel_mode = alc880_lg_lw_modes, 1696 - .input_mux = &alc880_lg_lw_capture_source, 1697 - .unsol_event = alc_sku_unsol_event, 1698 - .setup = alc880_lg_lw_setup, 1699 - .init_hook = alc_hp_automute, 1700 1775 }, 1701 1776 #ifdef CONFIG_SND_DEBUG 1702 1777 [ALC880_TEST] = {