You are not logged in.

#1 2017-10-28 12:31:33

jbssm
Member
Registered: 2017-10-28
Posts: 21

Can't get sound to work on new installation with ALSA.

Hi all,
I've been trying to get audio to work for the past few days to no avail.

The error I get in speaker test is:

~ >>> speaker-test -c2                                                                                              

speaker-test 1.1.4

Playback device is default
Stream parameters are 48000Hz, S16_LE, 2 channels
Using 16 octaves of pink noise
ALSA lib pcm_dmix.c:1099:(snd_pcm_dmix_open) unable to open slave
Playback open error: -2,No such file or directory

Some info:

~ >>> lspci -vnn | grep -A 1 -i audio                                                                               

00:01.1 Audio device [0403]: Advanced Micro Devices, Inc. [AMD/ATI] Kabini HDMI/DP Audio [1002:9840]
	Subsystem: Advanced Micro Devices, Inc. [AMD/ATI] Kabini HDMI/DP Audio [1002:9840]
	Flags: bus master, fast devsel, latency 0, IRQ 38

~ >>> cat /proc/asound/cards                                                                                     [1]
 0 [HDMI           ]: HDA-Intel - HDA ATI HDMI
                      HDA ATI HDMI at 0xfeb64000 irq 38

~ >>> aplay -l                                                                                                      
**** List of PLAYBACK Hardware Devices ****
card 0: HDMI [HDA ATI HDMI], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: HDMI [HDA ATI HDMI], device 7: HDMI 1 [HDMI 1]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

I tried adding:

$ cat /etc/modprobe.d/50-alsa.conf
options snd-hda-intel index=1,0

and then

$ cat /etc/modprobe.d/50-alsa.conf
options snd-hda-intel index=0,0

But they didn't work as well.

Offline

#2 2017-10-29 08:36:48

NumeroSMG
Member
Registered: 2016-08-23
Posts: 25

Re: Can't get sound to work on new installation with ALSA.

Heya,I just performed fresh install myself a few days ago and had issue with sound too.
Well, sort of, I first installed full gnome package and sound worked, then decided to go with LXDE where it didn't work, and after I couldn't make it to work went back to gnome again and the sound worked out of the box again...
I know it doesn't exactly fix your problem but there's that option if you want to try.

Offline

#3 2017-10-29 09:36:49

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,435

Re: Can't get sound to work on new installation with ALSA.

Your HDMI audio card is split into devices 3 and 7 of the card 0. ALSA, by default, plays back to the card hw:0,0 which doesn't exist in your case. Therefore try to figure out the correct device with

speaker-test -Dhw:0,3 -c2 #Or -Dhw:0,7

if you have the one that works, configure the default ALSA device to play back to in /etc/asound.conf or .asoundrc: 

defaults.pcm.device = 3 #Or 7

Offline

#4 2017-10-29 17:49:32

jbssm
Member
Registered: 2017-10-28
Posts: 21

Re: Can't get sound to work on new installation with ALSA.

Thank you V1del, unfortunately these aren't the answer.

They work in the command line, but none of them makes any sound. I tried this with 3 different cables and two different TV/monitors where the sound works fine with other equipment.

~ >>> speaker-test -Dhw:0,3 -c2                                                                      

speaker-test 1.1.4

Playback device is hw:0,3
Stream parameters are 48000Hz, S16_LE, 2 channels
Using 16 octaves of pink noise
Rate set to 48000Hz (requested 48000Hz)
Buffer size range from 64 to 1048576
Period size range from 32 to 524288
Using max buffer size 1048576
Periods = 4
was set period_size = 262144
was set buffer_size = 1048576
 0 - Front Left
 1 - Front Right
^CTime per period = 6.830027
~ >>> speaker-test -Dhw:0,7 -c2                                                                      

speaker-test 1.1.4

Playback device is hw:0,7
Stream parameters are 48000Hz, S16_LE, 2 channels
Using 16 octaves of pink noise
Rate set to 48000Hz (requested 48000Hz)
Buffer size range from 64 to 1048576
Period size range from 32 to 524288
Using max buffer size 1048576
Periods = 4
was set period_size = 262144
was set buffer_size = 1048576
 0 - Front Left
^C 1 - Front Right
Time per period = 1.239699

I'm lead to think that maybe there is some bug in the kernel driver or the ALSA regarding this ATI/AMD HDMI card.

Last edited by jbssm (2017-10-29 17:55:53)

Offline

#5 2017-10-29 18:25:00

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,435

Re: Can't get sound to work on new installation with ALSA.

Which card are we talking exactly?  You did unmute/enable the outputs with alsamixer?

Offline

#6 2017-10-29 18:28:18

Gusar
Member
Registered: 2009-08-25
Posts: 3,607

Re: Can't get sound to work on new installation with ALSA.

Are you using the amdgpu kernel driver? That one doesn't have HDMI audio support. It might with kernel 4.15 if Linus accepts AMD's new display code. Until then, you'll need to use a patched kernel. This might do the trick: https://aur.archlinux.org/packages/linux-4.13.y-dc

Offline

#7 2017-10-30 00:35:03

jbssm
Member
Registered: 2017-10-28
Posts: 21

Re: Can't get sound to work on new installation with ALSA.

V1del:
The card is the 00:01.1 Audio device [0403]: Advanced Micro Devices, Inc. [AMD/ATI] Kabini HDMI/DP Audio [1002:9840]

It's an integrated X3000 (Gen3) APU.

But yes I unmounted all the outputs. Although the outputs that show up in alsamixer are just 2 S/PDIF.

Gusar:
First I tried to install AMDGPU-PRO (according to the arch page it had HDMI audio output) but it didn't work. Although I'm not sure the system was using the AMDGPU-PRO driver, I just rebooted (according to the guide is enough).

I'm now waiting (for some hours) for the compilation of the linux-amd-staging-drm-next-git kernel to finish. Let's see if this finally solves the issue.

Offline

#8 2017-10-30 01:07:52

jbssm
Member
Registered: 2017-10-28
Posts: 21

Re: Can't get sound to work on new installation with ALSA.

Ok, the kernel finished compiling and after reboot the system freezes since it can't access the root system dir. I think this is because I'm using BTRFS and bcache and this kernel doesn't have support for at least one of those.

Offline

#9 2017-10-30 19:48:39

jbssm
Member
Registered: 2017-10-28
Posts: 21

Re: Can't get sound to work on new installation with ALSA.

Ok, after fiddling around there was a bug in the staging kernel for AMD that I had to solve by putting the block before autodetect in mkinitcpio

After that it boots up fine but... yet again, no sound trough the HDMI audio.

I'm starting to wonder why people praise so much AMD for linux... sincerely, with NVIDIA, all this just works and it works well.

All in all still no sound and a lot of bugs. Any ideas?

Last edited by jbssm (2017-10-30 19:50:01)

Offline

#10 2017-11-03 14:00:41

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 15,562

Re: Can't get sound to work on new installation with ALSA.

The X3000 apu appears to be rather new and intended for server use.
Is the firmware uptodate ?

Try with linux-amd-staging, mesa-git , llvm-svn and xf86-video-amdgpu-git .
Building all those will take a long time even on fast systems, you can find them in lordheavy's unofficial mesa-git repo .
I suggest reading https://bbs.archlinux.org/viewtopic.php?id=212819 before you start using it (atleast my opening post in it).


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

Board footer

Powered by FluxBB