* [PATCH] Fix swsusp-change-code-order-in-diskc.patch
@ 2007-01-25 12:36 Alexey Starikovskiy
2007-01-25 12:43 ` Pavel Machek
0 siblings, 1 reply; 3+ messages in thread
From: Alexey Starikovskiy @ 2007-01-25 12:36 UTC (permalink / raw)
To: Rafael J. Wysocki, Pavel Machek, Andrew Morton, Brown, Len,
Lebedev, Vladimir P, linux-pm
[-- Attachment #1: Type: text/plain, Size: 298 bytes --]
Hi,
Recent patch from Rafael changed the order of platform_prepare() and
swsusp_read(). platform_prepare() should happen before swsusp_read()
in order to get nice LED blinking during load of the image and time for
GPE activity to settle down.
Attaching the patch to fix order.
Regards,
Alex.
[-- Attachment #2: fix-swsusp-change-code-ordering-in-diskc.patch --]
[-- Type: text/plain, Size: 1150 bytes --]
Recent patch from Rafael changed the order of platform_prepare() and
swsusp_read(). platform_prepare() should happen before swsusp_read()
in order to get nice LED blinking during load of the image and time for
GPE activity to settle down.
From: Alexey Starikovskiy <alexey.y.starikovskiy@linux.intel.com>
LED blinking and time for GPE activity to stop.
---
kernel/power/disk.c | 11 ++++++-----
1 files changed, 6 insertions(+), 5 deletions(-)
diff --git a/kernel/power/disk.c b/kernel/power/disk.c
index 33e67b4..406b20a 100644
--- a/kernel/power/disk.c
+++ b/kernel/power/disk.c
@@ -240,21 +240,22 @@ static int software_resume(void)
goto Done;
}
- pr_debug("PM: Reading swsusp image.\n");
-
- error = swsusp_read();
+ error = platform_prepare();
if (error) {
swsusp_free();
goto Thaw;
}
- pr_debug("PM: Preparing devices for restore.\n");
+ pr_debug("PM: Reading swsusp image.\n");
- error = platform_prepare();
+ error = swsusp_read();
if (error) {
swsusp_free();
goto Thaw;
}
+
+ pr_debug("PM: Preparing devices for restore.\n");
+
suspend_console();
error = device_suspend(PMSG_PRETHAW);
if (error)
[-- Attachment #3: Type: text/plain, Size: 0 bytes --]
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] Fix swsusp-change-code-order-in-diskc.patch
2007-01-25 12:36 [PATCH] Fix swsusp-change-code-order-in-diskc.patch Alexey Starikovskiy
@ 2007-01-25 12:43 ` Pavel Machek
2007-01-25 12:51 ` Alexey Starikovskiy
0 siblings, 1 reply; 3+ messages in thread
From: Pavel Machek @ 2007-01-25 12:43 UTC (permalink / raw)
To: Alexey Starikovskiy; +Cc: Andrew Morton, linux-pm, Brown, Len
Hi!
> Recent patch from Rafael changed the order of platform_prepare() and
> swsusp_read(). platform_prepare() should happen before swsusp_read()
> in order to get nice LED blinking during load of the image and time for
> GPE activity to settle down.
Well, looks acceptable to me.
But if GPEs need some time to settle down, that should be done
explicitely, and with _big_ comment? What if your disk is too fast?
Also, same problem is likely present in uswsusp (and harder to fix
there). Is this really required?
Pavel
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Fix swsusp-change-code-order-in-diskc.patch
2007-01-25 12:43 ` Pavel Machek
@ 2007-01-25 12:51 ` Alexey Starikovskiy
0 siblings, 0 replies; 3+ messages in thread
From: Alexey Starikovskiy @ 2007-01-25 12:51 UTC (permalink / raw)
To: Pavel Machek; +Cc: Andrew Morton, linux-pm, Brown, Len
Pavel Machek wrote:
> Hi!
>
>
>> Recent patch from Rafael changed the order of platform_prepare() and
>> swsusp_read(). platform_prepare() should happen before swsusp_read()
>> in order to get nice LED blinking during load of the image and time for
>> GPE activity to settle down.
>>
>
> Well, looks acceptable to me.
>
> But if GPEs need some time to settle down, that should be done
> explicitely, and with _big_ comment? What if your disk is too fast?
>
> Also, same problem is likely present in uswsusp (and harder to fix
> there). Is this really required?
> Pavel
>
ACPI interrupt gets disabled if the GPE activity is not disabled before
switching to loaded image
on some Acer machines. In most cases disabling them just before
sw_switch() is enough, but it's better to
be on a safe side. And don't forget about blinking LED :)
Regards,
Alex.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-01-25 12:51 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-01-25 12:36 [PATCH] Fix swsusp-change-code-order-in-diskc.patch Alexey Starikovskiy
2007-01-25 12:43 ` Pavel Machek
2007-01-25 12:51 ` Alexey Starikovskiy
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox