Software suspend?
Cliff L. Biffle
cbiffle at safety.net
Thu Jun 26 10:08:27 PDT 2003
Have we considered implementing software suspend?
I've been using Gentoo on my laptops (as nobody else seems to be able to
reproduce my BSD bugs on them) and have been playing with the Linux software
suspend facilities. It's kind of a neat trick; basically they spawn a
process that forces everything else to page out as much as it can. When
simply paging the processes out is no longer possible, it stops the processes
and writes their remaining memory into swap manually. It then leaves some
sort of signature on the swap so that the kernel, on next boot, restores the
old memory space instead of firing up init and whatnot.
It's not quite perfect (for example, I don't believe it saves kernel space)
but it seems to work amazingly well for such a hack. :-)
I admit to being essentially unfamiliar with the innards of the FreeBSD kernel
and VM, but I've worked with the Linux patches (ugghhhh...I miss running
FreeBSD and not having to manually patch my kernel) and they're amazingly
simple, given their function.
How hard do y'all think this would be? Is anyone else interested in this? In
Linux it basically lets us work around broken ACPI suspend routines.
-Cliff L. Biffle
More information about the freebsd-current
mailing list