Red Hat Bugzilla – Bug 133749
Call "alsactl store" only if there is a sound card loaded
Last modified: 2014-03-16 22:48:42 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.3)
Description of problem:
/etc/rc.d/init.d/halt only check if the kernel provide alsa and then
store the current mixer setting.
But alsa can be loaded without a soundcard. This can erase
Version-Release number of selected component (if applicable):
Steps to Reproduce:
halt or reboot.
It's not really a initscript bug.
The problem is that /dev/snd/controlC0 (and
/sys/class/sound/controlC0) are in place even if there is no sound card.
This seems to be a alsa-driver bug.
Created attachment 104348 [details]
A little patch
Out of curiousity, when are you seeing alsa loaded without a soundcard?
Note that this won't work if you have a machine with only, say,
> Out of curiousity, when are you seeing alsa loaded without a soundcard?
With snd-dummy :-)
Never but who knows.
I was playing with "modprobe snd-xxxx" and "modprobe -r snd-xxxx" to
find out why sound setting is lose.
Find two cases :
- when sound setting is not restore (modprobe) and then after store
(with halt or "modprobe -r").
- When no sound card is loaded.
I repeat, it's not an initscript or alsactl bug.
It seems to me it's a kernel/alsa-driver bug.
If there is no sound card, then there shounld not be
/dev/snd/controlCX (udev) or device and then "alsactl store" should
But it's not what I see here (snd-ens1371 and snd-via82xx).
> Note that this won't work if you have a machine with only, say,
$ modinfo snd-intel8x0m.ko | grep depends
Why do you want to use alsactl if the card is not under the umbrella
of alsa ?
Anyway, if you want to close this bug with NOTABUG and drop my
fabulous patch, do it. Again, it's not an initscript bug.
Sorry for the noise.
What I mean is that if snd-intel8x0m is loaded, it will show as a
'card', but there's no audio settings to save for that device. :)
OK, closing as NOTABUG for now. With the new alsa-utils with the udev
fix, things *should* work correctly, as long as a initial volume is