* problem with suspend to disk on linux2.6-t9
@ 2003-11-17 22:27 dodger
2003-11-17 23:43 ` Måns Rullgård
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: dodger @ 2003-11-17 22:27 UTC (permalink / raw)
To: linux-kernel
hi
i am using linux2.6-t9 and i am trying to use suspend to disk
when doing a
< echo -n "disk" > /sys/power/state >
it is suspending real fine.
but it is not resuming at all.
i tried to boot up normally and with resume=/dev/hdb5 ( swap partition ) but
nothing happens...
it just boots up normally...
i have set /dev/hdb5 as DEFAULT RESUME PARTITION during kernel config...
any ideas?
thanks
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: problem with suspend to disk on linux2.6-t9
2003-11-17 22:27 problem with suspend to disk on linux2.6-t9 dodger
@ 2003-11-17 23:43 ` Måns Rullgård
2003-11-18 8:45 ` Rob Landley
2003-11-18 13:18 ` Rob Landley
2 siblings, 0 replies; 6+ messages in thread
From: Måns Rullgård @ 2003-11-17 23:43 UTC (permalink / raw)
To: linux-kernel
dodger <shoxx@web.de> writes:
> it is suspending real fine.
> but it is not resuming at all.
> i tried to boot up normally and with resume=/dev/hdb5 ( swap partition ) but
> nothing happens...
Try disabling the drive write cache with "hdparm -W0 /dev/hdb" before
suspending. It did the trick for me, as well as curing some other
obscure problems.
--
Måns Rullgård
mru@kth.se
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: problem with suspend to disk on linux2.6-t9
2003-11-17 22:27 problem with suspend to disk on linux2.6-t9 dodger
2003-11-17 23:43 ` Måns Rullgård
@ 2003-11-18 8:45 ` Rob Landley
2003-11-18 13:18 ` Rob Landley
2 siblings, 0 replies; 6+ messages in thread
From: Rob Landley @ 2003-11-18 8:45 UTC (permalink / raw)
To: shoxx, linux-kernel; +Cc: Patrick Mochel
On Monday 17 November 2003 16:27, dodger wrote:
> hi
> i am using linux2.6-t9 and i am trying to use suspend to disk
> when doing a
> < echo -n "disk" > /sys/power/state >
>
> it is suspending real fine.
> but it is not resuming at all.
> i tried to boot up normally and with resume=/dev/hdb5 ( swap partition )
> but nothing happens...
>
> it just boots up normally...
> i have set /dev/hdb5 as DEFAULT RESUME PARTITION during kernel config...
>
> any ideas?
> thanks
Hmmm... Looking at my dmesg from the last boot up (which was a clean boot and
not a resume from suspend), it doesn't seem like the suspend code prints out
anything when it's checking for a resume image. (On the other hand, the APIC
code prints out three screenfulls of useless trivia. Fun...)
Patrick: is there some kind of debug switch we can set to make it more
verbose? (I don't see one in the code. I'm going to be sprinkling in
printks myself as soon as my rebuild sans preempt finishes...)
Rob
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: problem with suspend to disk on linux2.6-t9
2003-11-17 22:27 problem with suspend to disk on linux2.6-t9 dodger
2003-11-17 23:43 ` Måns Rullgård
2003-11-18 8:45 ` Rob Landley
@ 2003-11-18 13:18 ` Rob Landley
2003-11-18 18:38 ` dodger
2003-11-18 21:00 ` Pavel Machek
2 siblings, 2 replies; 6+ messages in thread
From: Rob Landley @ 2003-11-18 13:18 UTC (permalink / raw)
To: shoxx, linux-kernel; +Cc: mochel
On Monday 17 November 2003 16:27, dodger wrote:
> hi
> i am using linux2.6-t9 and i am trying to use suspend to disk
> when doing a
> < echo -n "disk" > /sys/power/state >
>
> it is suspending real fine.
> but it is not resuming at all.
> i tried to boot up normally and with resume=/dev/hdb5 ( swap partition )
> but nothing happens...
>
> it just boots up normally...
> i have set /dev/hdb5 as DEFAULT RESUME PARTITION during kernel config...
>
> any ideas?
> thanks
Did you specify a default resume partition (CONFIG_PM_DISK_PARTITION) in your
.config? (Or provide it with the kernel parameter pmdisk=/dev/blah)...
On suspend, it saves to the first mounted swap file. On resume, it hasn't
looked at /etc/fstab yet to see where the swap files are by the time it gets
to resuming, and nobody's bothered to code up any heuristic for what to do
with no default partition, so you have to point it at a partition or it won't
attempt to resume.
Personally, I think that 99% of the time you can just iterate through the
partitions of whatever drive your root device lives on and find the first one
that's got a valid suspend signature on it, and resume from that. (And if
you don't find one, don't resume.) The few cases where this isn't
appropriate can configure another default or supply a kernel command line
paramenter, but having to bake your swap partition location into the kernel
config is a bit klunky at best...
Of course with lilo, there's a user space alternative, you know. Your suspend
script could call lilo -R with a command line that points to the partition
you're about to suspend to. But there are a number of problems with that
(ideally you want to do it right AFTER suspending...) And I dunno if grub's
got an equivalent...
One thing that might be nice is if there was a way to trigger a resume from
the initramfs. "Blow away the current process list and load this binary
image of what userspace should look like." That way figuring out where the
sucker lives is a problem you could punt on. :)
Rob
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: problem with suspend to disk on linux2.6-t9
2003-11-18 13:18 ` Rob Landley
@ 2003-11-18 18:38 ` dodger
2003-11-18 21:00 ` Pavel Machek
1 sibling, 0 replies; 6+ messages in thread
From: dodger @ 2003-11-18 18:38 UTC (permalink / raw)
To: linux-kernel
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Tuesday 18 November 2003 14:18, Rob Landley wrote:
> Did you specify a default resume partition (CONFIG_PM_DISK_PARTITION) in
> your .config? (Or provide it with the kernel parameter
> pmdisk=/dev/blah)...
yes i did.
i tried to suspend with disabled hdb write cache ( hdparm -W0 /dev/hdb ) and
it suspended and resumed fine.
exept for my network device wasnt running...is there a way to fix this?
i`ll try to do ifdown before suspending and ifup after resuming, but is
there a way to resume properly without that?
dodger
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org
iD8DBQE/umdKN+skZni2ETYRAnP9AJ9BgIfL5vwar1xJP1HqcjKkXezOcgCfSplv
7Vhwik+TieywXjgO2NWnXUQ=
=4Db2
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: problem with suspend to disk on linux2.6-t9
2003-11-18 13:18 ` Rob Landley
2003-11-18 18:38 ` dodger
@ 2003-11-18 21:00 ` Pavel Machek
1 sibling, 0 replies; 6+ messages in thread
From: Pavel Machek @ 2003-11-18 21:00 UTC (permalink / raw)
To: Rob Landley; +Cc: shoxx, linux-kernel, mochel
Hi!
> One thing that might be nice is if there was a way to trigger a resume from
> the initramfs. "Blow away the current process list and load this binary
> image of what userspace should look like." That way figuring out where the
> sucker lives is a problem you could punt on. :)
This is doable, but rather hard. Way too hard for 2.6.X, anyway.
Pavel
--
When do you have a heart between your knees?
[Johanka's followup: and *two* hearts?]
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2003-11-18 21:14 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-11-17 22:27 problem with suspend to disk on linux2.6-t9 dodger
2003-11-17 23:43 ` Måns Rullgård
2003-11-18 8:45 ` Rob Landley
2003-11-18 13:18 ` Rob Landley
2003-11-18 18:38 ` dodger
2003-11-18 21:00 ` Pavel Machek
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox