Page 1 of 1

Audio gone after F4 suspend and awaken

Posted: Thu Jul 06, 2006 9:37 pm
by fhuddles
Greetings,

I have a T20 running OpenSUSE 10.1, with a CS4614/22/24 [CrystalClear Sound Fusion Audio Accelerator] card (according to YaST). The driver is snd-cs46xx.
I have noticed that upon sleep via Fn-F4 and awaken, some audio playback no longer works. Specifically, the RealPlayer and mplayer applications appear to be connecting and playing an audio stream, but no sound actually comes out. mplayer appears to connect and fill its buffers, but the play statistics stay at zero. RealPlayer connects, fills its buffers, and says it is playing, but no sound is produced. KsCD, however, will play a CD and produce sound. Upon reboot, all systems return to normal: RealPlayer and mplayer once again produce sound.
I imagine that there's something I have to restart or reset upon awakening from sleep, but I don't know what it is. Can anyone help me with this?

Thanks,
Frank Huddleston

Posted: Fri Jul 07, 2006 1:44 am
by revolutionary_one
Hey.

Off the top of my head i can posit two possible reasons:

1)The sound module isnt being modprobe'd when you resume from standby mode. Try seeing if the module is loaded first and then if not modprobe it.

2)You dont have an effective sound mixer setup. Unless the distro provides for it the alsa sound drivers only allow one application to access to the sound device node created at one time. You'd need to setup a sound server to have multiple applications access the sound device at once or just free up whatever is using the sound device after resume from standby.

Cheers. Ramesh.

Posted: Fri Jul 07, 2006 8:30 am
by fhuddles
Thanks.
Concerning suggestion 1): is the "sound module" the same as the driver, in this case snd-cs46xx? From the /etc/modprobe.d/sound file, I see that it is aliased to
snd-card-0. I tried loading it with modprobe, and this is the result:
modprobe -v --first-time snd-card-0
FATAL: Module snd_cs46xx already in kernel.

so if that's the sound module, it looks as though it's already loaded. Is there something else I could check?

About 2): I don't think any other processes would be accessing the sound card, but how can I find this out? From another post I saw that someone was doing a
"fuser /dev/dsp", but this command for me either returns nothing or hangs.
How can I find out what my "sound device" is? How can I find out what process is using it?

Thanks,

Frank H.

Posted: Fri Jul 07, 2006 12:56 pm
by fhuddles
OK: I have found a way to restart sound after the suspend-to-RAM sleep. (by the way, my system uses APM, not ACPII):

sudo /etc/init.d/alsasound restart

There must be a way to put this in a sleep restart script; I'll find it eventually. If anyone happens to know where this is, I'd appreciate a tip...

Regards,

Frank H.