[linux-pm] Info on hibernation swap space requirement

Nigel Cunningham ncunningham at crca.org.au
Tue Nov 18 12:47:22 PST 2008


Hi Francesco.

On Tue, 2008-11-18 at 09:59 +0100, Francesco VIRLINZI wrote:
> Hi all.
> 
> I added the hibernation support on a sh4 based platform and it works fine,
>  but I don't understand how big the swap space has to be.
> 
> My system has 64Mb and I was assuming, I can freeze ~32 Mb therefore
>  I was creating a swap space of 40/50 Mb.
> 
> But it seems it isn't enough, the system is requiring more space.
> 
> Could you say me how evaluate the right (minimal) swap space required
>  when I know the DRam memory size.

If there's too much memory in use when hibernation is attempted, an
attempt will be made to free memory, which could involve pushing some
pages out to swap. You therefore probably want swap space to be at least
as big as the amount of memory you have, unless you're using the image
compression support that I think uswsusp has.

Please don't forget to post your code - we can then incorporate it in
vanilla and you won't have to worry about keeping it updated.

Nigel



More information about the linux-pm mailing list