Internal mic not working (HP EliteBook x360 1040 G5)

Does anyone have any ideas

It’s difficult to wade through the info because it seems this area changed a lot in the last ~3 years. But I finally found some up to date info: Configuration issues with AVS driver release · Issue #5 · thesofproject/avs-topology-xml · GitHub

Basically your device can use multiple drivers with varying degrees of support.

  • With the legacy snd_hda_intel, the built-in digital mic (DMIC) will not work. You ended up here with your changes previously by loading snd_hda_intel explicitly and also by setting options snd-intel-dspcfg dsp_driver=1 (although you’re only supposed to use the latter, and not load the module manually).

  • SOF’s Skylake driver was the solution for using DMIC up till recently; it can be set with dsp_driver=2. It seems like you’re currently using this (it’s being selected automatically) but it isn’t working correctly (also mentioned in the Arch forums link).

  • Skylake driver is being replaced by AVS driver in the near future; it can be set with dsp_driver=4. Not sure about support for your device, although 9d71 does show up in the driver code. Fedora has recent enough kernel and linux-firmware versions to use this.


Try AVS driver

So at this point, I think you should try the AVS driver.

Here’s a one-line command to do it:

echo 'options snd_intel_dspcfg dsp_driver=4' | sudo tee /etc/modprobe.d/audio-driver.conf

This creates a file /etc/modprobe.d/audio-driver.conf. If you want to try other values for dsp_driver later (2 or 3), edit this file instead of creating another one, so you don’t lose track and end up with conflicting changes. I recommend keeping notes on whatever you do :slight_smile:

But for now, reboot after doing the above, then see if your audio works (speakers, mic, and jack if you have headphones/headset to test). If it doesn’t work, grab the logs for me again:

(alsa-info.sh --stdout; pactl list) | fpaste

Undoing

To undo this change, remove the file:

sudo rm /etc/modprobe.d/audio-driver.conf

Hi Justin, thank you again for helping. Unfortunately it didn’t work. No change in output or input. I tried:

options snd_intel_dspcfg dsp_driver=4’

options snd_intel_dspcfg dsp_driver=3

options snd_intel_dspcfg dsp_driver=2’’

The link for the logs: UNTITLED - Pastebin Service

I just tried options snd_intel_dspcfg dsp_driver=1’ - this brings the audio output back but the internal speakers still not working.

I need the logs when you set options snd_intel_dspcfg dsp_driver=4. The AVS driver is the most likely way forward.

The last log is with dsp_driver=2. The results are the same as the previous one (right after you reinstalled), which just proves that it chooses 2 (the SOF Skylake driver) by default.

No worries, i have switched it back to 4 now and here is the log file UNTITLED - Pastebin Service

No worries, i have switched it back to 4 now and here is the log file UNTITLED - Pastebin Service

Copying the important part of the log here:

dmesg log for dsp_driver=4
[   15.427077] snd_soc_avs 0000:00:1f.3: enabling device (0000 -> 0002)
[   15.428425] snd_soc_avs 0000:00:1f.3: bound 0000:00:02.0 (ops i915_audio_component_bind_ops [i915])
[   15.485194] snd_soc_avs 0000:00:1f.3: cldma_irq_handler sd_status: 0x00000004
[   15.487907] snd_soc_avs 0000:00:1f.3: cldma_irq_handler sd_status: 0x00000004
[   15.506428] snd_hda_codec_conexant hdaudioB0D0: CX11970: BIOS auto-probing.
[   15.506921] snd_hda_codec_conexant hdaudioB0D0: autoconfig for CX11970: line_outs=1 (0x1d/0x0/0x0/0x0/0x0) type:speaker
[   15.506927] snd_hda_codec_conexant hdaudioB0D0:    speaker_outs=0 (0x0/0x0/0x0/0x0/0x0)
[   15.506930] snd_hda_codec_conexant hdaudioB0D0:    hp_outs=1 (0x16/0x0/0x0/0x0/0x0)
[   15.506933] snd_hda_codec_conexant hdaudioB0D0:    mono: mono_out=0x0
[   15.506935] snd_hda_codec_conexant hdaudioB0D0:    inputs:
[   15.506937] snd_hda_codec_conexant hdaudioB0D0:      Mic=0x19
[   15.508311] snd_hda_codec_conexant hdaudioB0D0: creating for CX11970 Analog 0
[   15.510248] snd_soc_avs 0000:00:1f.3: Direct firmware load for intel/avs/hda-14f120d0-tplg.bin failed with error -2
[   15.510254] snd_soc_avs 0000:00:1f.3: request topology "intel/avs/hda-14f120d0-tplg.bin" failed: -2
[   15.510258] snd_soc_avs 0000:00:1f.3: ASoC: error at snd_soc_component_probe on hdaudioB0D0-platform: -2
[   15.510270] avs_hdaudio avs_hdaudio.0: ASoC: failed to instantiate card -2
[   15.510583] avs_hdaudio: probe of avs_hdaudio.0 failed with error -2
[   15.518095] snd_hda_codec_hdmi hdaudioB0D2: creating for HDMI 0 0
[   15.518102] snd_hda_codec_hdmi hdaudioB0D2: skipping capture dai for HDMI 0
[   15.518104] snd_hda_codec_hdmi hdaudioB0D2: creating for HDMI 1 1
[   15.518107] snd_hda_codec_hdmi hdaudioB0D2: skipping capture dai for HDMI 1
[   15.518110] snd_hda_codec_hdmi hdaudioB0D2: creating for HDMI 2 2
[   15.518112] snd_hda_codec_hdmi hdaudioB0D2: skipping capture dai for HDMI 2
[   15.518207] snd_soc_avs 0000:00:1f.3: Direct firmware load for intel/avs/hda-8086280b-tplg.bin failed with error -2
[   15.518212] snd_soc_avs 0000:00:1f.3: request topology "intel/avs/hda-8086280b-tplg.bin" failed: -2
[   15.518217] snd_soc_avs 0000:00:1f.3: ASoC: error at snd_soc_component_probe on hdaudioB0D2-platform: -2
[   15.518229] avs_hdaudio avs_hdaudio.2: ASoC: failed to instantiate card -2
[   15.518384] avs_hdaudio: probe of avs_hdaudio.2 failed with error -2
[   15.518555] snd_soc_avs 0000:00:1f.3: Direct firmware load for intel/avs/dmic-tplg.bin failed with error -2
[   15.518560] snd_soc_avs 0000:00:1f.3: request topology "intel/avs/dmic-tplg.bin" failed: -2
[   15.518564] snd_soc_avs 0000:00:1f.3: ASoC: error at snd_soc_component_probe on dmic-platform: -2
[   15.518577] avs_dmic avs_dmic: ASoC: failed to instantiate card -2

It seems like it’s trying to find topology files in various locations. Specifically these 3:

intel/avs/hda-14f120d0-tplg.bin
intel/avs/hda-8086280b-tplg.bin
intel/avs/dmic-tplg.bin

I missed this part from the linked issue:

right now topology files are only published here and are not installed in /lib/firmware by default whenever you update or upgrade your distro.

These topology files need to be converted in 2 steps, and it seems you’ll need to compile avstplg first. I’ll need more time to look into this, or if you want to do it yourself then go ahead.

Otherwise, in the meantime I suggest you set dsp_driver=1 to get your speakers and jack working at least.

Thank you so much Justin! Your truly are a star!

I afraid I wouldn’t know how to do that so if its okay with you I will wait for you to work your magic. :slight_smile:

Justin, I installed Elementary and both mic and audio output working. Does this help to see what drivers or somthing that its using? :

neoque@HP-EliteBook-x360-1040-G5-2814480e:~$ grep -RC5 snd.*intel /etc/modprobe.d /usr/lib/modprobe.d /etc/alsa /usr/share/alsa
/etc/modprobe.d/alsa-base.conf-# Prevent abnormal drivers from grabbing index 0
/etc/modprobe.d/alsa-base.conf-options bt87x index=-2
/etc/modprobe.d/alsa-base.conf-options cx88_alsa index=-2
/etc/modprobe.d/alsa-base.conf-options saa7134-alsa index=-2
/etc/modprobe.d/alsa-base.conf-options snd-atiixp-modem index=-2
/etc/modprobe.d/alsa-base.conf:options snd-intel8x0m index=-2
/etc/modprobe.d/alsa-base.conf-options snd-via82xx-modem index=-2
/etc/modprobe.d/alsa-base.conf-options snd-usb-audio index=-2
/etc/modprobe.d/alsa-base.conf-options snd-usb-caiaq index=-2
/etc/modprobe.d/alsa-base.conf-options snd-usb-ua101 index=-2
/etc/modprobe.d/alsa-base.conf-options snd-usb-us122l index=-2

/etc/modprobe.d/blacklist.conf-blacklist de4x5
/etc/modprobe.d/blacklist.conf-
/etc/modprobe.d/blacklist.conf-# causes no end of confusion by creating unexpected network interfaces
/etc/modprobe.d/blacklist.conf-blacklist eth1394
/etc/modprobe.d/blacklist.conf-
/etc/modprobe.d/blacklist.conf:# snd_intel8x0m can interfere with snd_intel8x0, doesn’t seem to support much
/etc/modprobe.d/blacklist.conf-# hardware on its own (Ubuntu bug #2011, #6810)
/etc/modprobe.d/blacklist.conf:blacklist snd_intel8x0m
/etc/modprobe.d/blacklist.conf-
/etc/modprobe.d/blacklist.conf-# Conflicts with dvb driver (which is better for handling this device)
/etc/modprobe.d/blacklist.conf-blacklist snd_aw2
/etc/modprobe.d/blacklist.conf-
/etc/modprobe.d/blacklist.conf-# replaced by p54pci

/etc/modprobe.d/blacklist-modem.conf-# Uncomment these entries in order to blacklist unwanted modem drivers
/etc/modprobe.d/blacklist-modem.conf-# blacklist snd-atiixp-modem
/etc/modprobe.d/blacklist-modem.conf:# blacklist snd-intel8x0m
/etc/modprobe.d/blacklist-modem.conf-# blacklist snd-via82xx-modem

/usr/lib/modprobe.d/aliases.conf-# prevent unusual drivers from appearing as the first sound device ###########
/usr/lib/modprobe.d/aliases.conf-options snd-pcsp index=-2
/usr/lib/modprobe.d/aliases.conf-options snd-usb-audio index=-2
/usr/lib/modprobe.d/aliases.conf-options cx88_alsa index=-2
/usr/lib/modprobe.d/aliases.conf-options snd-atiixp-modem index=-2
/usr/lib/modprobe.d/aliases.conf:options snd-intel8x0m index=-2
/usr/lib/modprobe.d/aliases.conf-options snd-via82xx-modem index=-2
/usr/lib/modprobe.d/aliases.conf-
/usr/lib/modprobe.d/aliases.conf-# work around other kernel issues ############################################
/usr/lib/modprobe.d/aliases.conf-# The EHCI driver should be loaded before the ones for low speed controllers
/usr/lib/modprobe.d/aliases.conf-# or some devices may be confused when they are disconnected and reconnected.

Hm no, that doesn’t show it. Can you get the alsa logs?

I think it’s alsa-info on Debian-based distros, not alsa-info.sh.

alsa-info

This will prompt you to upload to alsa-project.org instead.

Okay great, here it is:
http://alsa-project.org/db/?f=f8c78c12da8271580c4cd57a48a099ca36545039

installed fedora again now, using driver=1

Oh, I didn’t realise you were installing one OS over another…

Anyway there’s a few things I note from the logs from Elementary:

  1. Kernel is older (5.19)

  2. It’s using the Skylake driver, the same as when you set dsp_driver=2 or don’t set anything (default).

  3. There’s a bunch of modprobe options, but none of them seem like they are related. None of those modules are even loaded on Fedora when you use the Skylake driver.

  4. They have the packages alsa-topology-conf and alsa-ucm-conf installed. The names are different on Fedora, alsa-topology and alsa-ucm.

    I just realised that alsa-ucm is installed by default, but alsa-topology isn’t.


Can you install alsa-topology:

sudo dnf install alsa-topology

Then set dsp_driver=2.

Hopefully this is all it takes, it’s not related to kernel, and we don’t need the AVS driver.

Sorry to say didnt do anything:

https://paste.centos.org/view/f45da820

It was to update this options snd_intel_dspcfg dsp_driver=2 in ```
/etc/modprobe.d/audio-driver.conf


Is that right? after the install of `alsa-topology`

Yes, you set it correctly. But there’s no change in the last log.

That leaves a few possibilities regarding Skylake driver. If you try anything, do it 1 at a time, and grab the logs as usual (state clearly which log is for what).

  1. There’re some other files/config on Elementary that makes it work.

    • I checked the Ubuntu 22.04 packages (which Elementary 7 is based on). The topology files seem to be the same as Fedora.

    • There’s some modprobe options that I said didn’t seem relevant, but I guess we might as well try it since it’s the easiest. I’ve extracted it from Ubuntu’s alsa-base. Download and copy this to /etc/modprobe.d/alsa-base.conf.

  2. Something changed between kernel 5.19 and 6.2 that breaks this.

    • There’s no easy way to use kernel 5.19 on current Fedora and it’s not a good idea because it’s not a LTS release (no more security fixes, unless you use a distro that supports 5.19 themselves). There is a 5.15 LTS on Copr though, but there’s no telling if it works, or breaks other things.
  3. Downgrade PipeWire. Just trying random things at this point.

    sudo dnf downgrade pipewire
    

    To undo, use upgrade:

    sudo dnf upgrade pipwire
    
  4. Swap to PulseAudio. Can’t really recommend it because it’ll be harder to support any audio issues in the future, but maybe you’re desperate or bored enough to try:

    sudo dnf swap pipewire-pulseaudio pulseaudio
    

    To undo, swap back:

    sudo dnf swap pulseaudio pipewire-pulseaudio
    

Otherwise, I’m still preparing the steps for trying the AVS driver.

Thank you again for helping. Those try s didn’t work.

There’s some modprobe options that I said didn’t seem relevant, but I guess we might as well try it since it’s the easiest. I’ve extracted it from Ubuntu’s alsa-base. Download and copy this 1 to /etc/modprobe.d/alsa-base.conf.

Result: no change UNTITLED - Pastebin Service

Downgrade PipeWire. Just trying random things at this point.

sudo dnf downgrade pipewire

Result: No change

https://paste.centos.org/view/12f627cc

Swap to PulseAudio. Can’t really recommend it because it’ll be harder to support any audio issues in the future, but maybe you’re desperate or bored enough to try:

sudo dnf swap pipewire-pulseaudio pulseaudio

Result:no change

Oh well. :sweat_smile: I don’t have any more ideas for the Skylake driver. I really don’t know how it works on Elementary, since every source says it shouldn’t work for your specific Conexant codec device.

No worries buddy, thank you for everything you are doing. I really appreciate it.