public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
From: Luca Capello <luca-wlebWZzHoyE@public.gmane.org>
To: ML ACPI-devel
	<acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org>
Subject: Re: clear/enable power button on resume
Date: Sun, 07 Mar 2004 20:38:03 +0100	[thread overview]
Message-ID: <404B7A1B.80006@pca.it> (raw)
In-Reply-To: <1078685555.541.9.camel-eqrHSpLoP5M@public.gmane.org>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hello,

on 03/07/04 19:52, Timo Hoenig wrote:
> after trying 2.6.4-rc1 I discovered some strange behavior: My machine
> simply shut down after resuming from S3.
>
> Since [ACPI] ACPICA 20040220 from Bob Moore there is code to
> clear/enable the power button on resume in acpi_leave_sleep_state().
> This leads to an acpi event which is handled by acpid if active. In my
> case acpid executed the corresponding shutdown script.
>
> I guess this is going to clutter many people.
this is a known problem at least for resuming from S1, please refers to the
thread called 'ASUS M3N and sleep states' started 20031227 by me or the direct
link to the relevant post here:
http://sourceforge.net/mailarchive/forum.php?thread_id=3676335&forum_id=6102

BTW, my simple workaround for S1 is using this trick on the ACPI power button
script:
=====
#!/bin/sh
#
# /etc/acpi/btn-power.sh

# shutdown
echo "Checking if resuming from S1..."
if tail -n 5 /var/log/messages | grep 'Restarting tasks... done'
then
	echo "Resuming from S1, so not acting, exited."
	exit 0
else
	echo "Shutdown in progress"
fi

if ps -Af | grep -q '[k]desktop' && test -f /usr/bin/dcop
then
    dcop --all-users ksmserver ksmserver logout 0 2 0 && exit 0
fi
/sbin/init 0
=====

Thx, bye,
Gismo / Luca
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)
Comment: Using GnuPG with Debian - http://enigmail.mozdev.org

iD8DBQFAS3oaVAp7Xm10JmkRAha3AJsF9j0VIFD4DHxXq/n8KpmgYiTFDACcCZ63
8pP1UHalIUnSpiRfibleBkU=
=58ik
-----END PGP SIGNATURE-----


-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click

  parent reply	other threads:[~2004-03-07 19:38 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-03-07 18:52 clear/enable power button on resume Timo Hoenig
     [not found] ` <1078685555.541.9.camel-eqrHSpLoP5M@public.gmane.org>
2004-03-07 19:38   ` Luca Capello [this message]
     [not found]     ` <404B7A1B.80006-wlebWZzHoyE@public.gmane.org>
2004-03-07 20:02       ` Timo Hoenig
     [not found]         ` <1078689765.541.20.camel-eqrHSpLoP5M@public.gmane.org>
2004-03-07 22:43           ` Sebastian Seifert
     [not found]             ` <20040307224318.GA1551-nlVyBo/8EO9N0TnZuCh8vA@public.gmane.org>
2004-03-07 23:27               ` Timo Hoenig

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=404B7A1B.80006@pca.it \
    --to=luca-wlebwzzhoye@public.gmane.org \
    --cc=acpi-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox