I met a similar issue before, but the difference is both sof driver and legacy 
hda driver can't detect mic, please see that commit header below:
commit 3f74249057827c5f6676c41c18f6be12ce1469ce
Author: Hui Wang <[email protected]>
Date:   Mon Sep 14 14:51:18 2020 +0800

    ALSA: hda/realtek - Couldn't detect Mic if booting with headset plugged
    
    We found a Mic detection issue on many Lenovo laptops, those laptops
    belong to differnt models and they have different audio design like
    internal mic connects to the codec or PCH, they all have this problem,
    the problem is if plugging a headset before powerup/reboot the
    machine, after booting up, the headphone could be detected but Mic
    couldn't. If we plug out and plug in the headset, both headphone and
    Mic could be detected then.


Maybe it could fix your machine too with a similar fix, add spec->codec_variant 
!= ALC269_TYPE_ALC255 like below:
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -3532,7 +3532,8 @@ static void alc256_shutup(struct hda_codec *codec)
         * when booting with headset plugged. So skip setting it for the codec 
alc257
         */
        if (spec->codec_variant != ALC269_TYPE_ALC257 &&
-           spec->codec_variant != ALC269_TYPE_ALC256)
+           spec->codec_variant != ALC269_TYPE_ALC256 &&
+           spec->codec_variant != ALC269_TYPE_ALC255)
                alc_update_coef_idx(codec, 0x46, 0, 3 << 12);


If you couldn't build the testing kernel, let me know, I will build a kernel 
with that change.

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1944575

Title:
  Acer Aspire 5 issue when headphone plug in before login

Status in linux package in Ubuntu:
  Confirmed

Bug description:
  Hello,

  Acer Aspire A515-56-57XR with ALC255 when headphone is plugged in before 
login causes few issues. I will list them below:
  - When headphones are plugged in and if I restart/shutdown-turn on the laptop 
and log in it does not detect headphones microphone at all and internal 
microphone is selected by default.
  - For output device headphones are plugged in but left/right channel is 
merged into both channels
  - To fix this need to re-plug the headphones/earphones and the issue goes 
away or after a restart/shutdown plug in only after logging in.
  - This issue does not occur when log off and log in only after a restart or 
cold boot from a shutdown while headphones/earphones are left plugged in.

  In another similar thread to this lots of other issues were fixed and they 
have been already merged into official kernel now. I will put a link to it 
below for reference. Looking to fix this issue now.
  https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1930188
  --- 
  ProblemType: Bug
  ApportVersion: 2.20.11-0ubuntu27.20
  Architecture: amd64
  AudioDevicesInUse:
   USER        PID ACCESS COMMAND
   /dev/snd/controlC0:  bijay      2343 F.... pulseaudio
  CasperMD5CheckResult: skip
  CurrentDesktop: ubuntu:GNOME
  DistroRelease: Ubuntu 20.04
  InstallationDate: Installed on 2021-04-19 (156 days ago)
  InstallationMedia: Ubuntu 20.04.1 LTS "Focal Fossa" - Release amd64 (20200731)
  Lsusb:
   Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
   Bus 001 Device 002: ID 0408:a061 Quanta Computer, Inc. HD User Facing
   Bus 001 Device 003: ID 8087:0026 Intel Corp. 
   Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
  MachineType: Acer Aspire A515-56
  Package: linux (not installed)
  ProcFB: 0 i915drmfb
  ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-5.11.0-34-generic 
root=UUID=9c557228-52d9-4013-9bdb-4e16712575d1 ro quiet splash vt.handoff=7
  ProcVersionSignature: Ubuntu 5.11.0-34.36~20.04.1-generic 5.11.22
  RelatedPackageVersions:
   linux-restricted-modules-5.11.0-34-generic N/A
   linux-backports-modules-5.11.0-34-generic  N/A
   linux-firmware                             1.187.16
  Tags:  focal
  Uname: Linux 5.11.0-34-generic x86_64
  UpgradeStatus: No upgrade log present (probably fresh install)
  UserGroups: adm cdrom dip docker lpadmin lxd plugdev sambashare sudo www-data
  _MarkForUpload: True
  dmi.bios.date: 05/26/2021
  dmi.bios.release: 1.12
  dmi.bios.vendor: Insyde Corp.
  dmi.bios.version: V1.12
  dmi.board.asset.tag: Type2 - Board Chassis Location
  dmi.board.name: Iris_TL
  dmi.board.vendor: TGL
  dmi.board.version: V1.12
  dmi.chassis.type: 10
  dmi.chassis.vendor: Acer
  dmi.chassis.version: V1.12
  dmi.ec.firmware.release: 1.12
  dmi.modalias: 
dmi:bvnInsydeCorp.:bvrV1.12:bd05/26/2021:br1.12:efr1.12:svnAcer:pnAspireA515-56:pvrV1.12:sku0000000000000000:rvnTGL:rnIris_TL:rvrV1.12:cvnAcer:ct10:cvrV1.12:
  dmi.product.family: Aspire 5
  dmi.product.name: Aspire A515-56
  dmi.product.sku: 0000000000000000
  dmi.product.version: V1.12
  dmi.sys.vendor: Acer

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1944575/+subscriptions


-- 
Mailing list: https://launchpad.net/~kernel-packages
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~kernel-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to