Thanks Mike and Theo. I'll test it with the new way.



Jes


On Tue, Nov 5, 2013 at 7:55 PM, Mike Larkin <[email protected]> wrote:

> On Tue, Nov 05, 2013 at 06:40:03PM +0100, Jes wrote:
> > Sorry, I don't understand you. You says the problem is solved since
> > yesterday (the snapshot my computer is running is from 03/11/2013), but
> at
> > the same time you says the swap size is not bib enough, but it's more
> than
> > the memory+64Mb (
> http://undeadly.org/cgi?action=article&sid=20120712101743).
> > And, in fact, my laptop hibernated one week ago (more or less).
> >
>
> The "old way" (up until yesterday) entailed the following:
>
> 1. Check if the default swap device (the one printed in autoconf) was the
> size of physical memory or greater. If not, abort hibernate.
>
> 2. Next, check if the range consuming the last "physical memory size"
> amount of swap was unallocated (eg, on an 8GB machine, check to make
> sure that the last 8GB was unallocated). If not, abort hibernate.
>
> You probably had something swapped out into that end range, so we aborted.
>
> But as Theo mentions, this discussion is moot due to the improvements
> that went in yesterday.
>
> > I have two swap partitions, sd1b and sd1j. The total amount of swap is
> > about 12G. I think with the small one (more than 3Gb) the system
> > hibernated, and with the 8Gb it did too.
>
> We currently only use the default swap device. Any extra swap you've got
> defined is ignored.
>
> >
> > Could you explain a bit more this?
> >
> > About the USB problem... thanks for solve it :)
> >
> > Thanks
> >
> > Jes
> >
> >
> > On Tue, Nov 5, 2013 at 6:23 PM, Theo de Raadt <[email protected]
> >wrote:
> >
> > > > This ocurrs in last two o three snapshots (I cannot be more precise)
> but
> > > it
> > > > used to work fine in current.
> > > >
> > > > Hibernation fails with the following message:
> > > >
> > > >
> > > > insufficient swap space for hibernate
> > > > acpi0: hibernate_suspend failed
> > >
> > > This problem has been there since the start.  Anyways, I fixed it
> > > yesterday.  It now will let you hibernate.  There are some range checks
> > > still missing in the code, and those are being improved...
> > >
> > > >   b:         17946495        177387840    swap
> > >
> > > No, it is not big enough.  The old calculation required a lot more
> > > overhead.  It was ridiculous.
> > >
> > > > Hibernation it's very useful due to a problem in my laptop (Thinkpad
> T410
> > > > with IvyBridge): no powered usb ports on resume after suspend.
> > > Hibernation
> > > > is a good replacement for suspend when it runs out of battery.
> > >
> > > This USB problem is about to be solved, a diff is coming from mpi@
> > >
> >
> > T

Reply via email to