You are not logged in.
Hello
I have installed Arch on a Lenovo IdeaPad Gaming 3 15ARH05 laptop. Out of box sound did not work for me even after unmuting everything. Nothing had sound in my window manager and speaker test had the following output:
$LANG=c speaker-test
speaker-test 1.2.6
Playback device is default
Stream parameters are 48000Hz, S16_LE, 1 channels
Using 16 octaves of pink noise
ALSA lib pcm_dmix.c:1032:(snd_pcm_dmix_open) unable to open slave
Playback open error: -2,No such file or directoryIt turned out I have two soundcards on my machine.
$LANG=c aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: NVidia [HDA NVidia], device 3: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: NVidia [HDA NVidia], device 7: HDMI 1 [HDMI 1]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: NVidia [HDA NVidia], device 8: HDMI 2 [HDMI 2]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: NVidia [HDA NVidia], device 9: HDMI 3 [HDMI 3]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: Generic [HD-Audio Generic], device 0: ALC257 Analog [ALC257 Analog]
Subdevices: 0/1
Subdevice #0: subdevice #0more detailed info:
$ LANG=c aplay -L
null
Discard all samples (playback) or generate zero samples (capture)
hdmi:CARD=NVidia,DEV=0
HDA NVidia, HDMI 0
HDMI Audio Output
hdmi:CARD=NVidia,DEV=1
HDA NVidia, HDMI 1
HDMI Audio Output
hdmi:CARD=NVidia,DEV=2
HDA NVidia, HDMI 2
HDMI Audio Output
hdmi:CARD=NVidia,DEV=3
HDA NVidia, HDMI 3
HDMI Audio Output
default:CARD=Generic
HD-Audio Generic, ALC257 Analog
Default Audio Device
sysdefault:CARD=Generic
HD-Audio Generic, ALC257 Analog
Default Audio Device
front:CARD=Generic,DEV=0
HD-Audio Generic, ALC257 Analog
Front output / input
surround21:CARD=Generic,DEV=0
HD-Audio Generic, ALC257 Analog
2.1 Surround output to Front and Subwoofer speakers
surround40:CARD=Generic,DEV=0
HD-Audio Generic, ALC257 Analog
4.0 Surround output to Front and Rear speakers
surround41:CARD=Generic,DEV=0
HD-Audio Generic, ALC257 Analog
4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=Generic,DEV=0
HD-Audio Generic, ALC257 Analog
5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=Generic,DEV=0
HD-Audio Generic, ALC257 Analog
5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=Generic,DEV=0
HD-Audio Generic, ALC257 Analog
7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
$LANG=c pactl list cards
Card #0
Name: alsa_card.pci-0000_01_00.1
Driver: module-alsa-card.c
Owner Module: 6
Properties:
alsa.card = "0"
alsa.card_name = "HDA NVidia"
alsa.long_card_name = "HDA NVidia at 0xd1000000 irq 79"
alsa.driver_name = "snd_hda_intel"
device.bus_path = "pci-0000:01:00.1"
sysfs.path = "/devices/pci0000:00/0000:00:01.1/0000:01:00.1/sound/card0"
device.bus = "pci"
device.vendor.id = "10de"
device.vendor.name = "NVIDIA Corporation"
device.product.id = "10fa"
device.string = "0"
device.description = "HDA NVidia"
module-udev-detect.discovered = "1"
device.icon_name = "audio-card-pci"
Profiles:
output:hdmi-stereo: Digital Stereo (HDMI) Ulostulo (sinks: 1, sources: 0, priority: 5900, available: no)
output:hdmi-surround: Digital Surround 5.1 (HDMI) Ulostulo (sinks: 1, sources: 0, priority: 800, available: no)
output:hdmi-surround71: Digital Surround 7.1 (HDMI) Ulostulo (sinks: 1, sources: 0, priority: 800, available: no)
output:hdmi-stereo-extra1: Digital Stereo (HDMI 2) Ulostulo (sinks: 1, sources: 0, priority: 5700, available: no)
output:hdmi-surround-extra1: Digital Surround 5.1 (HDMI 2) Ulostulo (sinks: 1, sources: 0, priority: 600, available: no)
output:hdmi-surround71-extra1: Digital Surround 7.1 (HDMI 2) Ulostulo (sinks: 1, sources: 0, priority: 600, available: no)
output:hdmi-stereo-extra2: Digital Stereo (HDMI 3) Ulostulo (sinks: 1, sources: 0, priority: 5700, available: no)
output:hdmi-surround-extra2: Digital Surround 5.1 (HDMI 3) Ulostulo (sinks: 1, sources: 0, priority: 600, available: no)
output:hdmi-surround71-extra2: Digital Surround 7.1 (HDMI 3) Ulostulo (sinks: 1, sources: 0, priority: 600, available: no)
output:hdmi-stereo-extra3: Digital Stereo (HDMI 4) Ulostulo (sinks: 1, sources: 0, priority: 5700, available: no)
output:hdmi-surround-extra3: Digital Surround 5.1 (HDMI 4) Ulostulo (sinks: 1, sources: 0, priority: 600, available: no)
output:hdmi-surround71-extra3: Digital Surround 7.1 (HDMI 4) Ulostulo (sinks: 1, sources: 0, priority: 600, available: no)
off: Poissa (sinks: 0, sources: 0, priority: 0, available: yes)
Active Profile: off
Ports:
hdmi-output-0: HDMI / DisplayPort (type: HDMI, priority: 5900, latency offset: 0 usec, not available)
Properties:
device.icon_name = "video-display"
Part of profile(s): output:hdmi-stereo, output:hdmi-surround, output:hdmi-surround71
hdmi-output-1: HDMI / DisplayPort 2 (type: HDMI, priority: 5800, latency offset: 0 usec, not available)
Properties:
device.icon_name = "video-display"
Part of profile(s): output:hdmi-stereo-extra1, output:hdmi-surround-extra1, output:hdmi-surround71-extra1
hdmi-output-2: HDMI / DisplayPort 3 (type: HDMI, priority: 5700, latency offset: 0 usec, not available)
Properties:
device.icon_name = "video-display"
Part of profile(s): output:hdmi-stereo-extra2, output:hdmi-surround-extra2, output:hdmi-surround71-extra2
hdmi-output-3: HDMI / DisplayPort 4 (type: HDMI, priority: 5600, latency offset: 0 usec, not available)
Properties:
device.icon_name = "video-display"
Part of profile(s): output:hdmi-stereo-extra3, output:hdmi-surround-extra3, output:hdmi-surround71-extra3
Card #1
Name: alsa_card.pci-0000_05_00.6
Driver: module-alsa-card.c
Owner Module: 7
Properties:
alsa.card = "1"
alsa.card_name = "HD-Audio Generic"
alsa.long_card_name = "HD-Audio Generic at 0xd15c0000 irq 80"
alsa.driver_name = "snd_hda_intel"
device.bus_path = "pci-0000:05:00.6"
sysfs.path = "/devices/pci0000:00/0000:00:08.1/0000:05:00.6/sound/card1"
device.bus = "pci"
device.vendor.id = "1022"
device.vendor.name = "Advanced Micro Devices, Inc. [AMD]"
device.product.id = "15e3"
device.product.name = "Family 17h (Models 10h-1fh) HD Audio Controller"
device.string = "1"
device.description = "Family 17h (Models 10h-1fh) HD Audio Controller"
module-udev-detect.discovered = "1"
device.icon_name = "audio-card-pci"
Profiles:
input:analog-stereo: Analoginen stereo Sisääntulo (sinks: 0, sources: 1, priority: 32833, available: yes)
output:analog-stereo: Analoginen stereo Ulostulo (sinks: 1, sources: 0, priority: 39268, available: yes)
output:analog-stereo+input:analog-stereo: Analoginen stereo, molemmat suunnat (sinks: 1, sources: 1, priority: 39333, available: yes)
off: Poissa (sinks: 0, sources: 0, priority: 0, available: yes)
Active Profile: output:analog-stereo+input:analog-stereo
Ports:
analog-input-internal-mic: Internal Microphone (type: Mic, priority: 8900, latency offset: 0 usec, availability unknown)
Properties:
device.icon_name = "audio-input-microphone"
Part of profile(s): input:analog-stereo, output:analog-stereo+input:analog-stereo
analog-input-mic: Microphone (type: Mic, priority: 8700, latency offset: 0 usec, not available)
Properties:
device.icon_name = "audio-input-microphone"
Part of profile(s): input:analog-stereo, output:analog-stereo+input:analog-stereo
analog-output-speaker: Speakers (type: Speaker, priority: 10000, latency offset: 0 usec, availability unknown)
Properties:
device.icon_name = "audio-speakers"
Part of profile(s): output:analog-stereo, output:analog-stereo+input:analog-stereo
analog-output-headphones: Headphones (type: Headphones, priority: 9900, latency offset: 0 usec, not available)
Properties:
device.icon_name = "audio-headphones"
Part of profile(s): output:analog-stereo, output:analog-stereo+input:analog-stereo I went to alsamixer and unmuted everything i could. Card 0 had S/PDIF labels on its outputs and I was able to unmute them but i was not able to raise their volume. On card 1 I was able to operate alsamixer normally.
I tested the two cards with speaker-test and got the following output
card 0: (no sound, weird unknown output)
$ speaker-test -Dhdmi:NVidia -c2
speaker-test 1.2.6
Playback device is hdmi:NVidia
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 - Unknown
1 - Unknown
Time per period = 20,212755
0 - Unknown
^C 1 - Unknown
Time per period = 2,351734card 1: (sound working, success)
speaker-test -Dsurround40:Generic -c2
speaker-test 1.2.6
Playback device is surround40:Generic
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
Time per period = 10,929188
0 - Front Left
^C 1 - Front RightI consulted the ALSA wiki page and made a /etc/asound.conf file in which i defined the default sound card to be the second card like so:
# change default souncard
defaults.pcm.card 1
defaults.ctl.card 1Now default speaker-test and sound on my window manager both work. But I have still no idea what is up with the other sound card. Is it bugged? Or am i understanding something fundamentally wrong about linux sound? Any insight on this is greatly appreciated.
Last edited by Hina (2021-12-29 02:40:33)
Offline
The other card is your HDMI audio card of the graphics card, if you have a monitor with speakers you could pass the audio via that. If you don't then you are not getting audio out of it, this is completely normal and has no relation to linux sound and would be the case on any other system as well.
FWIW, if you do have pulseaudio or pipewire installed you should remove that asound.conf and instead install pipewire-alsa/pulseaudio-alsa respectively. Otherwise you could run into unexpected behaviors with clients that support just ALSA.
Offline
Ah, I see.
I have pulseaudio and now that I installed the pulseaudio-alsa package my audio works like a charm without the asound.conf.
Thank you for the information and very fast reply! ![]()
Offline