* Re: [PATCH][0/3] swsusp: use non-contiguous memory
[not found] <200503042049.36873.rjw@sisk.pl>
@ 2005-03-04 20:09 ` Pavel Machek
0 siblings, 0 replies; only message in thread
From: Pavel Machek @ 2005-03-04 20:09 UTC (permalink / raw)
To: Rafael J. Wysocki; +Cc: Andrew Morton, Hu Gang, LKML
Hi!
> The following set of patches is designed to fix a problem in the current
> implementation of swsusp in mainline kernels. Namely, swsusp uses
> an array of page backup entries (aka pagedir) to store pointers to memory
> pages that must be saved during suspend and restored during resume.
>
> Unfortunately, the pagedir has to be located in a contiguous chunk of memory
> and it sometimes turns out that an 8-order or even 9-order allocation is needed
> for this purpose. It sometimes is impossible to get such an allocation and
> swsusp may fail during either suspend or resume due to the lack of memory,
> although theoretically there is enough free memory for it to succeed.
>
> Moreover, swsusp is more likely to fail for this reason during resume, which
> means that it may fail during resume after a successful suspend
> (this actually has happened for some people, including me :-)) and this,
> potentially, may lead to the loss of data.
>
> The problem is fixed by replacing the pagedir with a linklist so that
> high-order memory allocations are avoided (the patches make swsusp use only
> 0-order allocations). Unfortunately this means that it's necessary to change
> assembly routines used to restore the image after it's been loaded from
> swap so that they walk the list instead of walking the array.
>
> The patches are organized in the following way:
>
> [1] suspend part
> This patch makes swsusp allocate only individual pages during suspend.
> It does not require any changes to assembly routines and is
> architecture-independent.
> It has been present in the -mm kernels for some time.
> It contains some additional clean-ups and fixes from Pavel Machek
> and Adrian Bunk.
>
> [2] main resume part (core, i386, x86-64)
> This patch makes swsusp allocate only individual pages during resume.
> It contains the necessary changes to the assembly routines etc. for i386
> and x86-64.
> It depends on the suspend part.
>
> [3] resume part - ppc support
> This patch contains the necessary changes to the assembly routines
> etc. for ppc.
> It depends on the main resume part.
> It's a Hu Gang's patch.
>
> The patches are against 2.6.11.
>
> Well, I hope I did it right. ;-) Please consider for applying.
Wow, very nice summary. ACK on all 3 patches...
Pavel
--
People were complaining that M$ turns users into beta-testers...
...jr ghea gurz vagb qrirybcref, naq gurl frrz gb yvxr vg gung jnl!
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2005-03-04 20:22 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <200503042049.36873.rjw@sisk.pl>
2005-03-04 20:09 ` [PATCH][0/3] swsusp: use non-contiguous memory Pavel Machek
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).