Skip to content

Commit 0bd3eef

Browse files
tiwaiSasha Levin
authored andcommitted
ALSA: hda/realtek: Add quirk for HP Spectre x360 15-df1xxx
[ Upstream commit be0c40d ] HP Spectre x360 15-df1xxx with SSID 13c:863e requires similar workarounds that were applied to another HP Spectre x360 models; it has a mute LED only, no micmute LEDs, and needs the speaker GPIO seup. Link: https://bugzilla.kernel.org/show_bug.cgi?id=220054 Link: https://patch.msgid.link/20250427081035.11567-1-tiwai@suse.de Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent dba9b52 commit 0bd3eef

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed

sound/pci/hda/patch_realtek.c

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6963,6 +6963,41 @@ static void alc285_fixup_hp_spectre_x360_eb1(struct hda_codec *codec,
69636963
}
69646964
}
69656965

6966+
/* GPIO1 = amplifier on/off */
6967+
static void alc285_fixup_hp_spectre_x360_df1(struct hda_codec *codec,
6968+
const struct hda_fixup *fix,
6969+
int action)
6970+
{
6971+
struct alc_spec *spec = codec->spec;
6972+
static const hda_nid_t conn[] = { 0x02 };
6973+
static const struct hda_pintbl pincfgs[] = {
6974+
{ 0x14, 0x90170110 }, /* front/high speakers */
6975+
{ 0x17, 0x90170130 }, /* back/bass speakers */
6976+
{ }
6977+
};
6978+
6979+
// enable mute led
6980+
alc285_fixup_hp_mute_led_coefbit(codec, fix, action);
6981+
6982+
switch (action) {
6983+
case HDA_FIXUP_ACT_PRE_PROBE:
6984+
/* needed for amp of back speakers */
6985+
spec->gpio_mask |= 0x01;
6986+
spec->gpio_dir |= 0x01;
6987+
snd_hda_apply_pincfgs(codec, pincfgs);
6988+
/* share DAC to have unified volume control */
6989+
snd_hda_override_conn_list(codec, 0x14, ARRAY_SIZE(conn), conn);
6990+
snd_hda_override_conn_list(codec, 0x17, ARRAY_SIZE(conn), conn);
6991+
break;
6992+
case HDA_FIXUP_ACT_INIT:
6993+
/* need to toggle GPIO to enable the amp of back speakers */
6994+
alc_update_gpio_data(codec, 0x01, true);
6995+
msleep(100);
6996+
alc_update_gpio_data(codec, 0x01, false);
6997+
break;
6998+
}
6999+
}
7000+
69667001
static void alc285_fixup_hp_spectre_x360(struct hda_codec *codec,
69677002
const struct hda_fixup *fix, int action)
69687003
{
@@ -7743,6 +7778,7 @@ enum {
77437778
ALC280_FIXUP_HP_9480M,
77447779
ALC245_FIXUP_HP_X360_AMP,
77457780
ALC285_FIXUP_HP_SPECTRE_X360_EB1,
7781+
ALC285_FIXUP_HP_SPECTRE_X360_DF1,
77467782
ALC285_FIXUP_HP_ENVY_X360,
77477783
ALC288_FIXUP_DELL_HEADSET_MODE,
77487784
ALC288_FIXUP_DELL1_MIC_NO_PRESENCE,
@@ -9818,6 +9854,10 @@ static const struct hda_fixup alc269_fixups[] = {
98189854
.type = HDA_FIXUP_FUNC,
98199855
.v.func = alc285_fixup_hp_spectre_x360_eb1
98209856
},
9857+
[ALC285_FIXUP_HP_SPECTRE_X360_DF1] = {
9858+
.type = HDA_FIXUP_FUNC,
9859+
.v.func = alc285_fixup_hp_spectre_x360_df1
9860+
},
98219861
[ALC285_FIXUP_HP_ENVY_X360] = {
98229862
.type = HDA_FIXUP_FUNC,
98239863
.v.func = alc285_fixup_hp_envy_x360,
@@ -10541,6 +10581,7 @@ static const struct hda_quirk alc269_fixup_tbl[] = {
1054110581
SND_PCI_QUIRK(0x103c, 0x86c1, "HP Laptop 15-da3001TU", ALC236_FIXUP_HP_MUTE_LED_COEFBIT2),
1054210582
SND_PCI_QUIRK(0x103c, 0x86c7, "HP Envy AiO 32", ALC274_FIXUP_HP_ENVY_GPIO),
1054310583
SND_PCI_QUIRK(0x103c, 0x86e7, "HP Spectre x360 15-eb0xxx", ALC285_FIXUP_HP_SPECTRE_X360_EB1),
10584+
SND_PCI_QUIRK(0x103c, 0x863e, "HP Spectre x360 15-df1xxx", ALC285_FIXUP_HP_SPECTRE_X360_DF1),
1054410585
SND_PCI_QUIRK(0x103c, 0x86e8, "HP Spectre x360 15-eb0xxx", ALC285_FIXUP_HP_SPECTRE_X360_EB1),
1054510586
SND_PCI_QUIRK(0x103c, 0x86f9, "HP Spectre x360 13-aw0xxx", ALC285_FIXUP_HP_SPECTRE_X360_MUTE_LED),
1054610587
SND_PCI_QUIRK(0x103c, 0x8716, "HP Elite Dragonfly G2 Notebook PC", ALC285_FIXUP_HP_GPIO_AMP_INIT),
@@ -11457,6 +11498,7 @@ static const struct hda_model_fixup alc269_fixup_models[] = {
1145711498
{.id = ALC295_FIXUP_HP_OMEN, .name = "alc295-hp-omen"},
1145811499
{.id = ALC285_FIXUP_HP_SPECTRE_X360, .name = "alc285-hp-spectre-x360"},
1145911500
{.id = ALC285_FIXUP_HP_SPECTRE_X360_EB1, .name = "alc285-hp-spectre-x360-eb1"},
11501+
{.id = ALC285_FIXUP_HP_SPECTRE_X360_DF1, .name = "alc285-hp-spectre-x360-df1"},
1146011502
{.id = ALC285_FIXUP_HP_ENVY_X360, .name = "alc285-hp-envy-x360"},
1146111503
{.id = ALC287_FIXUP_IDEAPAD_BASS_SPK_AMP, .name = "alc287-ideapad-bass-spk-amp"},
1146211504
{.id = ALC287_FIXUP_YOGA9_14IAP7_BASS_SPK_PIN, .name = "alc287-yoga9-bass-spk-pin"},

0 commit comments

Comments
 (0)