No audio after (re)start (snd_hda_intel)

Hello Forum,

after a (re)start, I always have to manually re-configure the sound system via YasT2:

  • Start YaST2 / Audio;
  • Remove the “Family 17h (Models 00h-0fh) HD Audio Controller”, which is shown as “configured”;
  • Configure the Audio Controller using default settings.
  • Note: I leave the “Baffin HDMI/DP Audio [Radeon RX…]” untouched as “not configured”, as I don’t use it.

After this procedure, audio works flawlessly, but I have to perform it after every restart.

I checked the modules and detected that the following ones are not loaded after a restart:

ledtrig_audio, snd_hda_codec_generic, snd_hda_codec_realtek, snd_hda_codec_hdmi, snd_hda_codec_realtek, snd_seq, snd_seq_device

However, manually loading these modules, including restart of the services listed as dependecies for “sound.target”

alsa-restore.service, alsa-state.service, sound-extra.service

does not succeed.

Mainboard is an ASUS Prime X370-A, with Ryzen 7 1700X.
The issue appeared after upgrading from Leap 15.2.

Any ideas what is going wrong here, any what I can look after ?

Regards, Sven / “The Wumpus”

You have no mentions about audio chip you’re trying to use.

IMHO YaST audio setup is broken.
Try to delete all cards, restart, add all available cards, configure them, save settings, restart, test with DE sound goodies.
Check in YaST which audio device you are configuring by seeing Volume settings - onboard audio ALC1220/870/etc. has multiple outputs, a contraria to HDMI/DP.
YaST’s sound test may not work.
Try to use alsamixer (in a console).

It’s an ALC887-VD, but I think that this is not the issue as the chip is correctly detected if I re-configure via YaST2. Also, the chip is directly connected to the CPU “standard” audio interface, the driver is “snd_hda_intel” (I indeed forgot to merntion that).

I deleted all audio devices, restarted, and added them again - no difference, after another restart I have no audio again. If I change the volume settings via YaST2, I see all levers, the name is “Family 17h (Models 00h-0fh) HD Audio Controller”, no reference to the ALC887.

What however does not work is the test sound via YaST2, even after reconfiguring.

No difference, after restart and before reconfiguring, alsamixer says that no sound cards are insatalled. After reconfiguring, everything is ok.

So YaST2 is somehow not totally wrong as it correctly idenifies and configures the audio HW, I “just” need to do it after every restart.

Regards, Sven / “the_wumpus”

Please run the alsa-info.sh (diagnostic script) as per the following wiki page…
https://en.opensuse.org/SDB:Audio_troubleshooting#Script_to_run_to_obtain_detailed_information
…and report back with the link (to the uploaded file) that it provides.

It’s here: <link>](http://alsa-project.org/db/?f=0fa1ee8d3df9f11f97b6a8888c455fe62a1aee20)

!!Soundcards recognised by ALSA
!!-----------------------------

--- no soundcards ---


!!PCI Soundcards installed in the system
!!--------------------------------------

0a:00.1 Audio device [0403]: Advanced Micro Devices, Inc. [AMD/ATI] Baffin HDMI/DP Audio [Radeon RX 550 640SP / RX 560/560X] [1002:aae0]
    Subsystem: Micro-Star International Co., Ltd. [MSI] Device [1462:aae0]
0c:00.3 Audio device [0403]: Advanced Micro Devices, Inc. [AMD] Family 17h (Models 00h-0fh) HD Audio Controller [1022:1457]
    Subsystem: ASUSTeK Computer Inc. Device [1043:86c7]

Okay, this looks like a good place to start.

No loaded alsa modules at boot.

This might tell us more…

dmesg |grep snd

I note:


!!PCI Soundcards installed in the system
!!--------------------------------------

0a:00.1 Audio device [0403]: Advanced Micro Devices, Inc. [AMD/ATI] Baffin HDMI/DP Audio [Radeon RX 550 640SP / RX 560/560X] [1002:aae0]
    Subsystem: Micro-Star International Co., Ltd. [MSI] Device [1462:aae0]
0c:00.3 Audio device [0403]: Advanced Micro Devices, Inc. [AMD] Family 17h (Models 00h-0fh) HD Audio Controller [1022:1457]
    Subsystem: ASUSTeK Computer Inc. Device [1043:86c7]

The motherboard appears to have a 1022:1457 and 1043:86c7.

According to hardware for Linux: http://80.87.195.87/index.php?id=pci:8086-a2f0-1043-86c7 the 1043:86c7 is supported for audio.

I then looked for the 1022:1457 which notes this is supported by GNU/Linux with kernel versions 5.3 and newer
https://linux-hardware.org/index.php?id=pci:1022-1457-1849-6893

I note your kernel is Kernel release 5.3.18-59.19-preempt so one nominally expect that it is supported. I would not recommend you use the preempt kernel - possibly that is your problem.

The dmesg reports:


    1.949550] hdaudio hdaudioC0D0: Unable to bind the codec
    1.954551] hdaudio hdaudioC1D0: Unable to bind the codec

If the codec can’t be bound, I assume that means the alsa driver won’t properly load.

I recommend you go back to a default kernel.

Its puzzling that alsa is not loading. You could also try installing (if not already installed) alsa-firmware and kernel-firmware.

Here is the result:

HAL:/home/wumpus # dmesg | grep "snd"
    1.950321] snd_hda_intel 0000:0a:00.1: enabling device (0000 -> 0002)
    1.950405] snd_hda_intel 0000:0a:00.1: Force to non-snoop mode
    1.950776] snd_hda_intel 0000:0c:00.3: enabling device (0000 -> 0002)

Seems the devices are detected on boot ?

Also read oldcpu’s advice.

I needs to be taken into account that audio works if I recondigute it using YaST, without loading any additional SW or changing the kernel, as explained in the original post.

Meanwhile I also realized that if I only remove the 2nd (never used) audio device (“Baffin HDMI/DP Audio [Radeon RX…]”) within YaST, then the 1st audio device (“Family 17h (Models 00h-0fh) HD Audio Controller”) jumps to work - without reconfiguring it.

I did the alsa-info.sh again, the results are here.

Here dmesg reports (before reconfiguring in YaST)

    1.950321] snd_hda_intel 0000:0a:00.1: enabling device (0000 -> 0002)
    1.950405] snd_hda_intel 0000:0a:00.1: Force to non-snoop mode
    1.950776] snd_hda_intel 0000:0c:00.3: enabling device (0000 -> 0002)

No. You provide very terse information. Systemd has fine capabilities: https://www.digitalocean.com/community/tutorials/systemd-essentials-working-with-services-units-and-the-journal Show what is going on:

**3400G:~ #** journalctl -b -q -o short-monotonic _KERNEL_SUBSYSTEM=hdaudio  
    5.082875] 3400G kernel: snd_hda_codec_realtek hdaudioC2D0: autoconfig for ALC887-VD: line_outs=1 (0x14/0x0/0x0/0x0/0x0) type:line 
    5.082878] 3400G kernel: snd_hda_codec_realtek hdaudioC2D0:    speaker_outs=0 (0x0/0x0/0x0/0x0/0x0) 
    5.082880] 3400G kernel: snd_hda_codec_realtek hdaudioC2D0:    hp_outs=1 (0x1b/0x0/0x0/0x0/0x0) 
    5.082881] 3400G kernel: snd_hda_codec_realtek hdaudioC2D0:    mono: mono_out=0x0 
    5.082882] 3400G kernel: snd_hda_codec_realtek hdaudioC2D0:    dig-out=0x11/0x0 
    5.082883] 3400G kernel: snd_hda_codec_realtek hdaudioC2D0:    inputs: 
    5.082883] 3400G kernel: snd_hda_codec_realtek hdaudioC2D0:      Front Mic=0x19 
    5.082885] 3400G kernel: snd_hda_codec_realtek hdaudioC2D0:      Rear Mic=0x18 
    5.082885] 3400G kernel: snd_hda_codec_realtek hdaudioC2D0:      Line=0x1a 
**3400G:~ #**

USB audio:

**3400G:~ #** journalctl -b -q -o short-monotonic _KERNEL_SUBSYSTEM=usb -g 1-10               
    4.285598] 3400G kernel: usb 1-10: new full-speed USB device number 3 using xhci_hcd 
    4.619244] 3400G kernel: usb 1-10: New USB device found, idVendor=1130, idProduct=1620, bcdDevice= 1.40 
    4.619249] 3400G kernel: usb 1-10: New USB device strings: Mfr=0, Product=2, SerialNumber=0 
    4.619251] 3400G kernel: usb 1-10: Product: USB  AUDIO   
    5.125610] 3400G kernel: **usb ****1-10****: Warning! Unlikely big volume range (=17152), cval->res is probably wrong.**
    5.125614] 3400G kernel: **usb ****1-10****: [2] FU [PCM Playback Volume] ch = 2, val = 0/17152/1**
**3400G:~ #**

Presumably audio starts too early on your system for some reason. What are your device units?

**3400G:~ #** systemctl list-unit-files '*sound*'                                             
UNIT FILE           STATE  VENDOR PRESET
alsasound.service   **alias  **-            
sound-extra.service static -            
sound.target        static -            

3 unit files listed. 
**3400G:~ #** systemctl list-units '*sound*'      
  UNIT                                                                                                   LOAD   ACTIVE SUB     DESCRIPTION                                                            
  sys-devices-pci0000:00-0000:00:01.2-0000:01:00.0-usb1-1\x2d10-1\x2d10:1.0-sound-card0-controlC0.device loaded active plugged USB_AUDIO 
  sys-devices-pci0000:00-0000:00:08.1-0000:08:00.1-sound-card1-controlC1.device                          loaded active plugged /sys/devices/pci0000:00/0000:00:08.1/0000:08:00.1/sound/card1/controlC1 
  sys-devices-pci0000:00-0000:00:08.1-0000:08:00.6-sound-card2-controlC2.device                          loaded active plugged /sys/devices/pci0000:00/0000:00:08.1/0000:08:00.6/sound/card2/controlC2
  sound.target                                                                                           loaded active active  Sound Card 

LOAD   = Reflects whether the unit definition was properly loaded. 
ACTIVE = The high-level unit activation state, i.e. generalization of SUB. 
SUB    = The low-level unit activation state, values depend on unit type. 
**4 loaded units listed.** Pass --all to see loaded but inactive units, too. 
To show all installed unit files use 'systemctl list-unit-files'. 
**3400G:~ #**

I am very sorry, that was not my intention.

However, I just installed some updates - and now it works. It seems that no kernel or firmware files were updated, but a lot systemd- and udev-related stuff was.

Thank you for the assistance - plus reputation for everyone trying to help me !

Regards, Sven / the_wumpus

Glad to read that sound is now working. Thanks for the update.