Unix Technical Forum

Alsa laptop suspend. Won't stop, won't start, but works?

This is a discussion on Alsa laptop suspend. Won't stop, won't start, but works? within the Gentoo Linux Support forums, part of the Unix Operating Systems category; --> I have been googling and searching the forums about Alsa problems with suspending and resuming. The general solution is ...


Go Back   Unix Technical Forum > Unix Operating Systems > Gentoo Linux Support

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-21-2008, 04:47 AM
jorussel@cisco.com
 
Posts: n/a
Default Alsa laptop suspend. Won't stop, won't start, but works?

I have been googling and searching the forums about Alsa problems with
suspending and resuming. The general solution is to stop Alsa before
apm suspends and the start it up again on resume. Ok sounds
good. However, this is what happens. I _just_ rebooted to be sure that
I didn't screw it up with a previous suspend....


mendelssohn:/etc/init.d# ./alsasound stop
* WARNING: you are stopping a boot service.
* Shutting down ALSA modules....
snd-mixer-oss: Device or resource busy
snd-intel8x0: Device or resource busy
snd-pcm: Device or resource busy
snd-timer: Device or resource busy
snd-mpu401-uart: Device or resource busy
snd-rawmidi: Device or resource busy
snd-seq-device: Device or resource busy
snd-ac97-codec: Device or resource busy
snd: Device or resource busy

mendelssohn:/etc/init.d# ./alsasound status
* status: stopped
mendelssohn:/etc/init.d# ./alsasound start
* ALSA driver is already running.
mendelssohn:/etc/init.d# ./alsasound status
* status: stopped
mendelssohn:/etc/init.d# ./alsasound stop
* ERROR: "alsasound" has not yet been started.
mendelssohn:/etc/init.d# ./alsasound start
* ALSA driver is already running.
mendelssohn:/etc/init.d# ./alsasound zap
mendelssohn:/etc/init.d# ./alsasound start
* ALSA driver is already running.
mendelssohn:/etc/init.d# ./alsasound stop
* ERROR: "alsasound" has not yet been started.


And after all this, sound continues to work fine.
AAAAAHHHHH!!!!!. Does anyone know what is going on? I'd love to put
/etc/init.d/alsasound stop in the apm suspend script, but it doesn't
work for me normally. Thanks for any help.

For the record. I am running an IBM THinkpad A31p.

mendelssohn:/var/lib/init.d/started# uname -a
Linux mendelssohn 2.4.21 #1 Fri Jun 13 17:40:44 EDT 2003 i686 Mobile
Intel(R) Pentium(R) 4 - M CPU 2.00GHz GenuineIntel GNU/Linux

John
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-21-2008, 04:48 AM
Stefan Majewski
 
Posts: n/a
Default Re: Alsa laptop suspend. Won't stop, won't start, but works?

Am Tue, 24 Jun 2003 09:31:54 -0400 schrieb jorusse:

[snip resource busy]

> And after all this, sound continues to work fine.


Well, of course. You haven't managed to unload the modules. Something
might use the resource. I am thinking of some sound daemon of your
windowmanager or something alike. You would have to stop this first.

> AAAAAHHHHH!!!!!. Does anyone know what is going on? I'd love to put
> /etc/init.d/alsasound stop in the apm suspend script, but it doesn't
> work for me normally. Thanks for any help.
>
> For the record. I am running an IBM THinkpad A31p.


Are you using artsd, esd or something like that?

Just for your information, have a look at the recent developments of the
acpi-developers. The patch for the 2.5. Kernel works for me. Never got apm
to work properly.


Stefan

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 02-21-2008, 04:48 AM
jorussel@cisco.com
 
Posts: n/a
Default Re: Alsa laptop suspend. Won't stop, won't start, but works?

"Stefan Majewski" <stefanmajewski@gmx.de> writes:

> Just for your information, have a look at the recent developments of the
> acpi-developers. The patch for the 2.5. Kernel works for me. Never got apm
> to work properly.
>
>
> Stefan


I saw there was a large ACPI patch in the 2.4.22 prepatch. Do you
know if this was merged down from the 2.5. tree?

John
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 02-21-2008, 04:48 AM
jorussel@cisco.com
 
Posts: n/a
Default Re: Alsa laptop suspend. Won't stop, won't start, but works?

"Stefan Majewski" <stefanmajewski@gmx.de> writes:

>
> Just for your information, have a look at the recent developments of the
> acpi-developers. The patch for the 2.5. Kernel works for me. Never got apm
> to work properly.
>
>
> Stefan


I got the 2.4.22 kernel and compiled with ACPI. I am now running
acpid and the appropriate events seem to be showing up in the
/var/log/acpid file.

e.g when I close my laptop lid, messages appear reflecting the event.


So now what.

Do you have a useful /etc/acpi/events/* file that makes suspend and
resume and things work for you?

Are there any graphical battery state displays such as the gnome panel
battery applet?

Thanks for the help.

John
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 02-21-2008, 04:48 AM
Stefan Majewski
 
Posts: n/a
Default Re: Alsa laptop suspend. Won't stop, won't start, but works?

Am Tue, 24 Jun 2003 16:56:25 -0400 schrieb jorusse:

> So now what.


Well, that's it. Maybe you have throttling support now, which can save
some energy or your fans are working as intended (On many acpi-compliant
systems this is not the case without the acpi-patch)
If you want the sleep-states, you would unfortunately have to go for the
2.5.x Kernel for it is only supportet for 2.5.x's driver-model. Nevertheless,
not all drivers are changed to the new model, so suspend does
unfortunately not yet work with every given setting. I bet your system
support S1, S3 and S4 sleep states on acpi. S4 is software-suspend (aka
suspend to disk) which works fairly good here. S3 is suspend to ram and
the use of S1 hasn't shown to me yet, for not even the backlight is
switched out. S4 works on my Vaio FX505, but S3 unfortunately not yet. But
I have read reports that it behaves quite well on some machines, so maybe
your's is one of the lucky ones ;-). Don't fiddle with S5, for it switches
your computer off, without syncing the disks.

> Do you have a useful /etc/acpi/events/* file that makes suspend and
> resume and things work for you?


That has nothing to do with the events file. The acpid is just there to
handle the various events acpi can give. Like powerswitch,
suspend-switch... The suspension is done by adding something like

echo -n 4 > /proc/acpi/sleep

to the appropriate event (The suspend key)

> Are there any graphical battery state displays such as the gnome panel
> battery applet?


I am not using these things, but I read that some of the applets, in their
latest versions, are capable of reading acpi. I have looked into the
xosview code myself, which is fairly easy to patch.


Stefan
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 12:06 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com