Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
No alsa sound on HP zBook 17 G6 / Intel i7-9850H
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
dib.gentoo
n00b
n00b


Joined: 29 Oct 2018
Posts: 10

PostPosted: Sun Jul 25, 2021 12:28 pm    Post subject: No alsa sound on HP zBook 17 G6 / Intel i7-9850H Reply with quote

Hi,

with my new laptop (HP zBook 17 G6 / Intel i7-9850H) I do not have sound with alsa anymore...

cat /proc/asound/cards shows only the Thunderbolt Dockingstation Audio Headset with device number 2 (but it does not work, no sound there either).

The internal on chip sound is not there.

The hdmi sound is not there, too.

With "lspci | grep Audio", I get only the Nvidia device, nothing else.

With "lsusb | grep Audio", I get "HP, Inc USB Audio", which I suppose is the Thunderbolt Dock, which I can use with alsa, but does not work.

Lots of googling brought up some things I tried in /etc/modprobe.d/alsa.conf:
- option snd cards_limit=5
- snd-hda-intel dmic_detect=0 # seems to be deprecated, so I tried:
- snd-intel-dspcfg dsp_driver=1
- snd-hda-intel model=laptop-amic enable=yes

Somewhere I read that disabling the pcspkr could help, so I blacklisted those modules.
I also tried blacklisting snd_soc_skl.

Nothing helped.

Any hints?
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54214
Location: 56N 3W

PostPosted: Sun Jul 25, 2021 12:39 pm    Post subject: Reply with quote

dib.gentoo,

Lets start by looking at your hardware. Please post the output of
Code:
lspci -nnk

That should show your HDMI and motherboard sound cards, then we can work out the drivers you need.

Likewise,
Code:
lsusb
will show any connected USB sound devices.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
dib.gentoo
n00b
n00b


Joined: 29 Oct 2018
Posts: 10

PostPosted: Sun Jul 25, 2021 2:37 pm    Post subject: Reply with quote

lspci -nnk output: http://dpaste.com/6BM2BW8DM
lsusb output: http://dpaste.com/9Y4CNVC6G
dmesg output: http://dpaste.com/6AGEW3SUJ
/etc/modprobe.d/alsa.conf (grown over time, not even sure anymore which changes I made): http://dpaste.com/2DMGT8YRF

Kernel Version is 5.13.4, but I also tried with 5.11 and 5.12 before that...
alsa-lib, alsa-firmware, alsa-utils 1.2.4
Back to top
View user's profile Send private message
misphit
n00b
n00b


Joined: 20 Jun 2017
Posts: 7
Location: 3 m below sealevel

PostPosted: Sun Jul 25, 2021 3:13 pm    Post subject: Reply with quote

dib.gentoo,

HP makes use of the conexant hdaudio chip.
You should enable in your kernel:

config_snd_hda_intel
config_snd_hda_hwdep
config_snd_hda_codec_hdmi
config_snd_hda_codec_connexant
config_snd_hda_intel_hdmi_silent_stream

and also:
config_snd_pci, (without choosing any of the options that follow)

If you also want the Bang and Olufsen speakers to work,
which are actually very nice, you shoud enable config_pcspkr_platform.

After all this, snd_hda_codec_conexant_hdaudio should show in your dmesg.

HTH, misphit
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54214
Location: 56N 3W

PostPosted: Sun Jul 25, 2021 3:32 pm    Post subject: Reply with quote

dib.gentoo,

Your on board audio device is
Code:
00:1f.3 Multimedia audio controller [0401]: Intel Corporation Cannon Lake PCH cAVS [8086:a348] (rev 10)
   Subsystem: Hewlett-Packard Company Cannon Lake PCH cAVS [103c:860c]
   Kernel driver in use: snd_hda_intel
   Kernel modules: snd_hda_intel, snd_soc_skl, snd_sof_pci_intel_cnl

That all looks good.
Your Video card Audio is
Code:
01:00.1 Audio device [0403]: NVIDIA Corporation TU106 High Definition Audio Controller [10de:10f9] (rev a1)
   Subsystem: Hewlett-Packard Company TU106 High Definition Audio Controller [103c:860e]
   Kernel driver in use: snd_hda_intel
   Kernel modules: snd_hda_intel

which looks good too.

That's the PCI bus digital interface to the sound chips. They also have an output interface that is not shown there, called the CODEC.
CODECs have their own kernel options.

Your USB information shows
Code:
Bus 005 Device 006: ID 03f0:0269 HP, Inc USB Audio
Bus 001 Device 002: ID 04f2:b669 Chicony Electronics Co., Ltd HP HD Camera

The webcam may or may not have its own microphone.

The USB audio devices require snd_usb_audio support in the kernel.
The video card requires snd_hda_codec_hdmi in the kernel.

Now there is a twist in the kernel configuration. snd_hda_intel and all the dodecs that it will use must be configured either all as built in <*> or all as loadable modules <M>.
Some <*> and some <M> failes as all the bits have to be available when snd_hda_intel initialises.
Further, /etc/modprobe.d/alsa.conf cannot be consulted when everything is built in. Its on the root filesystem, which is not mounted when built in snd_hda_intel initialises.

When all the bits are in place, your on board sound card will be card0, the HDMI sound card will be card1 and the USB devices will be 2 and maybe 3.

dmesg says
Code:
[   53.984235] hdaudio hdaudioC1D0: Unable to bind the codec
[   53.989593] hdaudio hdaudioC0D0: Unable to bind the codec

Which confirms the codec issues I outlined above.

Code:
[   55.225646] usbcore: registered new interface driver snd-usb-audio

That's good. The driver is loaded, but it will be muted.

Try
Code:
alsamixer -c0
to see if you can find the controls, then -c1, -c2 until you get an error.
Card0 is the default, so if its not card 0, it won't work without some alsa configuration. Well, VLC can use it, but it won't be the default.

One last thing. Detecting the codec you need for the on board audio isn't easy, so enable them all.
alsamixer will tell you want it is, then you can remove the extra codecs with your next kernel update.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
dib.gentoo
n00b
n00b


Joined: 29 Oct 2018
Posts: 10

PostPosted: Sun Jul 25, 2021 6:37 pm    Post subject: Reply with quote

Ok, this already helped a lot! Thank you very much!

What I did now: I took the config from the "gentoo-kernel" (which is derived from the fedora kernel config) and did the changes you suggested, with turning these parts to built in (y). This is the diffconfig:
AC97_BUS m -> y
LEDS_TRIGGER_AUDIO m -> y
REGMAP_SPI m -> y
SND m -> y
SND_COMPRESS_OFFLOAD m -> y
SND_CTL_LED m -> y
SND_DMAENGINE_PCM m -> y
SND_HDA m -> y
SND_HDA_CODEC_ANALOG m -> y
SND_HDA_CODEC_CA0110 m -> y
SND_HDA_CODEC_CA0132 m -> y
SND_HDA_CODEC_CIRRUS m -> y
SND_HDA_CODEC_CMEDIA m -> y
SND_HDA_CODEC_CONEXANT m -> y
SND_HDA_CODEC_HDMI m -> y
SND_HDA_CODEC_REALTEK m -> y
SND_HDA_CODEC_SI3054 m -> y
SND_HDA_CODEC_SIGMATEL m -> y
SND_HDA_CODEC_VIA m -> y
SND_HDA_CORE m -> y
SND_HDA_GENERIC m -> y
SND_HDA_INTEL m -> y
SND_HWDEP m -> y
SND_INTEL_DSP_CONFIG m -> y
SND_INTEL_SOUNDWIRE_ACPI m -> y
SND_PCM m -> y
SND_RAWMIDI m -> y
SND_SEQ_DEVICE m -> y
SND_SOC m -> y
SND_SOC_I2C_AND_SPI m -> y
SND_TIMER m -> y
SND_USB_AUDIO m -> y
SOUND m -> y

All outputs are working! But I had to try it with VLC, because of course now, I have the problem that the HDMI card is index 0.

No matter what I did with /etc/asound.conf or ~/.asoundconf, neither VLC nor Firefox used the cards I configured as default there (I tried the hints from https://wiki.gentoo.org/wiki/ALSA).

So the next step would be to find out which kernel settings I need to set to "m" now (or what else I need to change), so my /etc/modprobe.d/alsa.conf can set the index of the cards in the correct order - as all I changed to "y" was already "m" before - and it didn't work that way...

Or is there any way I can change the default output for e.g. firefox "on the fly"? As I would like to switch between speakers, headphones and HDMI quite regularly anyway...
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54214
Location: 56N 3W

PostPosted: Sun Jul 25, 2021 7:02 pm    Post subject: Reply with quote

dib.gentoo,

You can set the sound card index on the kernel command line for built in code.
See the top of /usr/src/linux/Documentation/admin-guide/kernel-parameters.rst

/etc/asound.conf also works. You need three lines.
Code:
defaults.pcm.card 1
defaults.pcm.device 8
defaults.ctl.card 1


To give you the numbers you need, post the content of /proc/asound/devices and tell us which device you would like to be the default.

My /etc/asound.conf above says default to card 1 device 8 and use the controls for card 1.
That's my active HDMI output but alsa does not care what the hardware is.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
dib.gentoo
n00b
n00b


Joined: 29 Oct 2018
Posts: 10

PostPosted: Mon Jul 26, 2021 5:12 am    Post subject: Reply with quote

Thank you all!!
It works now!!
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54214
Location: 56N 3W

PostPosted: Mon Jul 26, 2021 10:42 am    Post subject: Reply with quote

dib.gentoo,

Please share what you did, so others finding this topic can follow it.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum