This is a note to let you know that I've just added the patch titled ALSA: hda/realtek: fix a determine_headset_type issue for a Dell AIO to the 5.10-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: alsa-hda-realtek-fix-a-determine_headset_type-issue-for-a-dell-aio.patch and it can be found in the queue-5.10 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. >From febf22565549ea7111e7d45e8f2d64373cc66b11 Mon Sep 17 00:00:00 2001 From: Hui Wang <hui.wang@xxxxxxxxxxxxx> Date: Sat, 20 Mar 2021 17:15:41 +0800 Subject: ALSA: hda/realtek: fix a determine_headset_type issue for a Dell AIO From: Hui Wang <hui.wang@xxxxxxxxxxxxx> commit febf22565549ea7111e7d45e8f2d64373cc66b11 upstream. We found a recording issue on a Dell AIO, users plug a headset-mic and select headset-mic from UI, but can't record any sound from headset-mic. The root cause is the determine_headset_type() returns a wrong type, e.g. users plug a ctia type headset, but that function returns omtp type. On this machine, the internal mic is not connected to the codec, the "Input Source" is headset mic by default. And when users plug a headset, the determine_headset_type() will be called immediately, the codec on this AIO is alc274, the delay time for this codec in the determine_headset_type() is only 80ms, the delay is too short to correctly determine the headset type, the fail rate is nearly 99% when users plug the headset with the normal speed. Other codecs set several hundred ms delay time, so here I change the delay time to 850ms for alc2x4 series, after this change, the fail rate is zero unless users plug the headset slowly on purpose. Cc: <stable@xxxxxxxxxxxxxxx> Signed-off-by: Hui Wang <hui.wang@xxxxxxxxxxxxx> Link: https://lore.kernel.org/r/20210320091542.6748-1-hui.wang@xxxxxxxxxxxxx Signed-off-by: Takashi Iwai <tiwai@xxxxxxx> Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx> --- sound/pci/hda/patch_realtek.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c @@ -5256,7 +5256,7 @@ static void alc_determine_headset_type(s case 0x10ec0274: case 0x10ec0294: alc_process_coef_fw(codec, coef0274); - msleep(80); + msleep(850); val = alc_read_coef_idx(codec, 0x46); is_ctia = (val & 0x00f0) == 0x00f0; break; Patches currently in stable-queue which might be from hui.wang@xxxxxxxxxxxxx are queue-5.10/alsa-hda-realtek-fix-a-determine_headset_type-issue-for-a-dell-aio.patch queue-5.10/alsa-hda-realtek-call-alc_update_headset_mode-in-hp_automute_hook.patch