FS#15829 - Sound card numbering is inconsistent and sound module snd_hda_codec_atihdmi can't be blacklisted
Attached to Project:
Arch Linux
Opened by Heiko Baums (cyberpatrol) - Thursday, 06 August 2009, 12:24 GMT
Last edited by Aaron Griffin (phrakture) - Monday, 10 August 2009, 20:40 GMT
Opened by Heiko Baums (cyberpatrol) - Thursday, 06 August 2009, 12:24 GMT
Last edited by Aaron Griffin (phrakture) - Monday, 10 August 2009, 20:40 GMT
|
Details
Description:
Since the last update, I can't use my audio card anymore without manually reconfiguring audio players after every system booting. I've got the audio card M-Audio Audiophile 24/96 and the graphics card ATI Radeon HD3450. For the audio card I'm using the kernel module snd-ice1712 and for the graphics card I'm using xf86-video-radeonhd-git from AUR (the same issue exists with xf86-video-radeonhd from extra). For MOC I set "AlsaDevice = plughw:0" in ~/.moc/config, because I only have one sound/audio card in my PC. MOC now can't find a usable audio card anymore and alsamixer somehow showed me a sound card named "HDA ATI HDMI". lsmod shows me now the modules snd_hda_codec_atihdmi, snd_hda_codec and snd_hda_intel, even if my graphics card doesn't have a HDMI interface. snd_hda_codec_atihdmi got the sound card #0. And my only real sound card got sound card #1. But reconfiguring MOC to "AlsaDevice = plughw:1" doesn't work, because of inconsistencies in the sound card numbering. Sometimes the unnecessary HDMI sound device is sound card #0 and the needed ICE1712 sound device is sound card #1, and sometimes it's vice versa. Blacklisting snd_hda_codec_atihdmi by adding "!snd_hda_codec_atihdmi" to the MODULES array in /etc/rc.conf doesn't help. This module is loaded anyway. And putting "snd-ice1712" at the beginning of the MODULES array, also doesn't help with the inconsistent card numbering. This must be fixed somehow. I don't need and don't want such a HDMI sound module, I need a consistent sound card numbering and I need the real sound card as the default sound card #0 as usual. Additional info: * package version(s) initscripts 2009.07-3 filesystem 2009.07-1 udev 141-5 alsa-lib 1.0.20-1 kernel26 2.6.30.4-1 |
This task depends upon
Closed by Aaron Griffin (phrakture)
Monday, 10 August 2009, 20:40 GMT
Reason for closing: Not a bug
Additional comments about closing: Fixed with the use of the index= module parameter
Monday, 10 August 2009, 20:40 GMT
Reason for closing: Not a bug
Additional comments about closing: Fixed with the use of the index= module parameter
FS#12706implemented.This is not considered a bug.
Try http://wiki.archlinux.org/index.php/ALSA#Set_the_default_sound_card to get consistent order.
I am not sure why blacklisting does not work though.
@devs: any ideas on this? (did I miss some change in this area?)
But I managed it to blacklist the module snd_hda_codec_atihdmi by blacklisting the modules snd_hda_intel and snd_hda_codec, too.
I haven't read
FS#12706, yet, but I really don't like - or let me say hate - booting anything in the background or parallel etc. This makes booting only slightly faster, but can lead to many big troubles like this one. And such a parallel booting brings only such a little time saving, that the troubles prevail. I'll readFS#12706later, and probably write a comment to this bug. So I'd suggest to revert the implementation ofFS#12706. There are already options for /etc/rc.multi to load daemons in the background. If someone thinks, he needs this, he can do it but only on his own responsibility. Btw., how often is a PC booted? Is it really important, if it needs 1 or 2 seconds longer to boot?Did you do this by prefixing them with ! in MODULES?
If yes then I'm for closing this report.
Please comment about
FS#12706in that report (after reading it first), not here.snd_hda_codec_atihdmi is not a soundcard. It's a codec. If your indexes are random on your sound card modules, set the index option in a modprobe config file for each sound card.
Secondly:
FS#12706will not be reverted because of people with 2 sound cards. This is an edge case. The average user has 1 sound card. Additionally, you can, and SHOULD control sound cards via the index property that the modules provideI don't think, this bug should be closed, because there are people, who are using 2 sound cards and need a consistent sound card numbering, which is currently not possible. So this needs to be fixed.
snd_hda_codec_atihdmi may not be a sound card but a codec, but it is recognized by alsa as a sound card and gets a sound card number. Tell me, if this is an upstream bug in alsa. Then I'll file a bug report for alsa.
I don't think, that having 2 sound cards is an edge case. Even if it was one, those people, too, need a stable and consistent system. A Linux distribution, especially Arch Linux ;-), is not only for the average user. If you, Aaron, mean with "control sound cards via the index property" the method in the wiki, Roman, has linked to, then this doesn't work at least not with snd-ice1712 and snd_hda_codec_atihdmi.
# ALSA portion
options snd cards_limit=2
alias snd-card-0 snd-ice1712
alias snd-card-1 snd-hda-intel
options snd-ice1712 index=0
options snd-hda-intel index=1
# OSS/Free portion
alias sound-slot-0 snd-ice1712
alias sound-slot-1 snd-hda-intel
So the wiki is not quite wrong, but incomplete. I'll add the missing parts to the wiki.
To blacklist the ATI HDMI modules, it is sufficient to blacklist the module snd-hda-intel in the MODULES array. The other 2 modules are loaded by snd-hda-intel.
Maybe now this bug can be closed. ;-)
$ modprobe --show-depends snd-hda-intel
insmod /lib/modules/2.6.30-ARCH/kernel/sound/core/snd-page-alloc.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/soundcore.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/core/snd.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/core/snd-timer.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/core/snd-pcm.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/core/snd-hwdep.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/pci/hda/snd-hda-codec.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/pci/hda/snd-hda-intel.ko
$ modprobe --show-depends snd-hda-codec-atihdmi
insmod /lib/modules/2.6.30-ARCH/kernel/sound/core/snd-page-alloc.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/soundcore.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/core/snd.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/core/snd-timer.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/core/snd-pcm.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/core/snd-hwdep.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/pci/hda/snd-hda-codec.ko
insmod /lib/modules/2.6.30-ARCH/kernel/sound/pci/hda/snd-hda-codec-atihdmi.ko
I took the lines in my last comment from the "Module Autoloading Support" section in http://www.mjmwired.net/kernel/Documentation/sound/alsa/ALSA-Configuration.txt, which is the first link in the wiki. And I can remember, that an older version of alsaconf puts these lines into modprobe.conf resp. modules.conf. And I can remember having read this somewhere in a documentation, possibly the "Gentoo Linux ALSA Guide". But it's not in this guide anymore.
These pages also show something similar:
http://alsa.opensrc.org/index.php/MultipleCards
http://alsa.opensrc.org/index.php/FAQ
In http://www.mjmwired.net/kernel/Documentation/sound/alsa/ALSA-Configuration.txt there's also a list of ALSA modules. The only HDA module there is snd-hda-intel, which is also for ATI graphics cards. And as you've written, snd_hda_codec_atihdmi and snd_hda_codec are just codecs. The only sound card driver is snd-hda-intel. So from this point of view it makes sense, that only this module needs to be blacklisted.
If you know a similar solution for the eventX input drivers in /dev/input and /dev/input/by-path in
FS#15828this would be great. At least Roman had the idea, that this could be similar.So please simplify the wiki section to reflect this fact.
Thank you for modifying the wiki, BTW. This is really appreciated.