From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Rafael J. Wysocki" Subject: Re: [RFC][PATCH 3/4] swsusp: Introduce restore platform operations Date: Tue, 22 May 2007 01:55:43 +0200 Message-ID: <200705220155.44430.rjw@sisk.pl> References: <200705180019.35548.rjw@sisk.pl> <200705180024.52170.rjw@sisk.pl> <20070521233848.GN10714@elf.ucw.cz> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Return-path: Received: from ogre.sisk.pl ([217.79.144.158]:51747 "EHLO ogre.sisk.pl" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753959AbXEUXua (ORCPT ); Mon, 21 May 2007 19:50:30 -0400 In-Reply-To: <20070521233848.GN10714@elf.ucw.cz> Content-Disposition: inline Sender: linux-acpi-owner@vger.kernel.org List-Id: linux-acpi@vger.kernel.org To: Pavel Machek Cc: ACPI Devel Maling List , pm list , Alexey Starikovskiy , Johannes Berg On Tuesday, 22 May 2007 01:38, Pavel Machek wrote: > Hi! > > > From: Rafael J. Wysocki > > > > At least on some machines it is necessary to prepare the ACPI firmware for the > > restoration of the system memory state from the hibernation image if the > > "platform" mode of hibernation has been used. Namely, in that cases we need to > > disable the GPEs before replacing the "boot" kernel with the "frozen" kernel. > > After the restore they will be re-enabled by hibernation_ops->finish(), but if > > the restore fails, they have to be re-enabled by the restore code explicitly. > > > > For this purpose we can introduce two additional hibernation operations, called > > pre_restore() and restore_cleanup() and call them from the restore code path. > > Still, they should be called if the "platform" mode of hibernation has been > > used, so we need to pass the information about the hibernation mode from the > > "frozen" kernel to the "boot" kernel in the image header. > > I don't quite like this one... passing flags from frozen to boot > kernel makes it more complex. > > Is it really neccessary? I think so. > Could we do the same steps as the first thing when the frozen kernel > wakes up? At that time we do hibernate_ops->finish() which enables the GPEs anyway in the right place. > What machines does it fix? http://bugzilla.kernel.org/show_bug.cgi?id=7887 Greetings, Rafael