Skip to contentSkip to conversation

Headset Mic no show at resume back

PATCH Applied Kailang 2 participants 2 messages Mar 1, 2024 Sound

lore
Share & tools
lore

Kailang

author
#0 lore raw

Hi Takashi,

Attach patch will fix headset Mic no show issue.

BR,
Kailang

From 9e32013bce2090c8345380f94b70520c31608589 Mon Sep 17 00:00:00 2001
From: Kailang Yang <[email protected]>
Date: Fri, 1 Mar 2024 15:29:50 +0800
Subject: [PATCH] ALSA: hda/realtek - Fix headset Mic no show at resume back for Lenovo ALC897 platform

Headset Mic will no show at resume back.
This patch will fix this issue.

Fixes d7f32791a9fc ("ALSA: hda/realtek - Add headset Mic support for Lenovo ALC897 platform")
sound/pci/hda/patch_realtek.c +5 -2
index f112eb1a868f..d71520858b5f 100644
@@ -11571,8 +11571,7 @@ static void alc897_hp_automute_hook(struct hda_codec *codec,
 
 	snd_hda_gen_hp_automute(codec, jack);
 	vref = spec->gen.hp_jack_present ? (PIN_HP | AC_PINCTL_VREF_100) : PIN_HP;
-	snd_hda_codec_write(codec, 0x1b, 0, AC_VERB_SET_PIN_WIDGET_CONTROL,
-			    vref);
+	snd_hda_set_pin_ctl(codec, 0x1b, vref);
 }
 
 static void alc897_fixup_lenovo_headset_mic(struct hda_codec *codec,
@@ -11581,6 +11580,10 @@ static void alc897_fixup_lenovo_headset_mic(struct hda_codec *codec,
 	struct alc_spec *spec = codec->spec;
 	if (action == HDA_FIXUP_ACT_PRE_PROBE) {
 		spec->gen.hp_automute_hook = alc897_hp_automute_hook;
+		spec->no_shutup_pins = 1;
+	}
+	if (action == HDA_FIXUP_ACT_PROBE) {
+		snd_hda_set_pin_ctl_cache(codec, 0x1a, PIN_IN | AC_PINCTL_VREF_100);
 	}
 }
 
Applied
#1 lore raw
Quoted 4 lines · Kailang

Hi Takashi,

Attach patch will fix headset Mic no show issue.

Thanks, applied now.

Takashi