Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 93c9d8ae authored by Takashi Iwai's avatar Takashi Iwai
Browse files

ALSA: hda - Don't re-initialize shared hp/mic pinctl



When a headphone pin is set up as a shared hp/mic pin, we rather want
to keep it as a headphone primarily as default, but the driver
overrides it always as a mic pin, just because the input controls are
created after outputs.  Add a check of pin NID and skip the
re-initialization of pinctl for such a shared hp/mic pin.

Reported-by: default avatarJonathan Woithe <jwoithe@just42.net>
Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent d5702162
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -2967,6 +2967,7 @@ static int create_input_ctls(struct hda_codec *codec)
		val = PIN_IN;
		if (cfg->inputs[i].type == AUTO_PIN_MIC)
			val |= snd_hda_get_default_vref(codec, pin);
		if (pin != spec->hp_mic_pin)
			set_pin_target(codec, pin, val, false);

		if (mixer) {