public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@ucw.cz>
To: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: pm list <linux-pm@lists.linux-foundation.org>,
	ACPI Devel Maling List <linux-acpi@vger.kernel.org>
Subject: Re: [RFC][PATCH 1/2] ACPI: Do not prepare for hibernation in acpi_shutdown
Date: Wed, 4 Jul 2007 21:49:05 +0200	[thread overview]
Message-ID: <20070704194905.GH2728@elf.ucw.cz> (raw)
In-Reply-To: <200707012053.08663.rjw@sisk.pl>

Hi!

> Since we are now explicitly calling hibernation_ops->prepare() before
> hibernation_ops->enter() in hibernation_platform_enter() (defined in
> kernel/power/disk.c), ACPI should not call acpi_sleep_prepare(ACPI_STATE_S4)
> from acpi_shutdown().
> 
> Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
> ---
>  drivers/acpi/sleep/poweroff.c |    3 ---
>  1 file changed, 3 deletions(-)
> 
> Index: linux-2.6.22-rc6/drivers/acpi/sleep/poweroff.c
> ===================================================================
> --- linux-2.6.22-rc6.orig/drivers/acpi/sleep/poweroff.c	2007-07-01 15:08:54.000000000 +0200
> +++ linux-2.6.22-rc6/drivers/acpi/sleep/poweroff.c	2007-07-01 15:10:07.000000000 +0200
> @@ -54,9 +54,6 @@ static int acpi_shutdown(struct sys_devi
>  	case SYSTEM_POWER_OFF:
>  		/* Prepare to power off the system */
>  		return acpi_sleep_prepare(ACPI_STATE_S5);
> -	case SYSTEM_SUSPEND_DISK:
> -		/* Prepare to suspend the system to disk */
> -		return acpi_sleep_prepare(ACPI_STATE_S4);
>  	default:
>  		return 0;

Hmm, I do not see why this is unneccessary... acpi wants to be
notified of poweroff, and hooks in a pretty reasonable
way. kernel/power does not seem to call acpi_sleep_prepare(). Hmm?

								Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

  reply	other threads:[~2007-07-04 19:49 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-01 18:51 [RFC][PATCH 0/2] PM: Update system power off code Rafael J. Wysocki
2007-07-01 18:53 ` [RFC][PATCH 1/2] ACPI: Do not prepare for hibernation in acpi_shutdown Rafael J. Wysocki
2007-07-04 19:49   ` Pavel Machek [this message]
2007-07-04 21:40     ` Rafael J. Wysocki
2007-07-01 18:54 ` [RFC][PATCH 2/2] PM: Introduce pm_power_off_prepare Rafael J. Wysocki
2007-07-04 19:52   ` Pavel Machek
2007-07-04 21:42     ` Rafael J. Wysocki
2007-07-04 21:39       ` Pavel Machek
2007-07-04 21:52         ` Rafael J. Wysocki

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=20070704194905.GH2728@elf.ucw.cz \
    --to=pavel@ucw.cz \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-pm@lists.linux-foundation.org \
    --cc=rjw@sisk.pl \
    /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