dect
/
linux-2.6
Archived
13
0
Fork 0
This repository has been archived on 2022-02-17. You can view files and clone it, but cannot push or open issues or pull requests.
linux-2.6/kernel/power
Rafael J. Wysocki d6277db4ab [PATCH] swsusp: rework memory shrinker
Rework the swsusp's memory shrinker in the following way:

- Simplify balance_pgdat() by removing all of the swsusp-related code
  from it.

- Make shrink_all_memory() use shrink_slab() and a new function
  shrink_all_zones() which calls shrink_active_list() and
  shrink_inactive_list() directly for each zone in a way that's optimized
  for suspend.

In shrink_all_memory() we try to free exactly as many pages as the caller
asks for, preferably in one shot, starting from easier targets.   If slab
caches are huge, they are most likely to have enough pages to reclaim.
 The inactive lists are next (the zones with more inactive pages go first)
etc.

Each time shrink_all_memory() attempts to shrink the active and inactive
lists for each zone in 5 passes.   In the first pass, only the inactive
lists are taken into consideration.   In the next two passes the active
lists are also shrunk, but mapped pages are not reclaimed.   In the last
two passes the active and inactive lists are shrunk and mapped pages are
reclaimed as well.  The aim of this is to alter the reclaim logic to choose
the best pages to keep on resume and improve the responsiveness of the
resumed system.

Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: Con Kolivas <kernel@kolivas.org>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
2006-06-23 07:42:48 -07:00
..
Kconfig help text: SOFTWARE_SUSPEND doesn't need ACPI 2006-04-01 01:03:08 +02:00
Makefile [PATCH] swsusp: userland interface 2006-03-23 07:38:07 -08:00
console.c [PATCH] Fix build failure in recent pm_prepare_* changes. 2006-02-07 16:12:33 -08:00
disk.c [PATCH] swsusp: freeze user space processes first 2006-03-23 07:38:08 -08:00
main.c [PATCH] suspend_console() warning fix 2006-06-22 15:05:56 -07:00
pm.c [PATCH] remove kernel/power/pm.c:pm_unregister() 2006-04-14 12:25:26 -07:00
power.h [PATCH] swsusp: add s2ram ioctl to userland interface 2006-03-23 07:38:08 -08:00
poweroff.c [PATCH] Use kernel_power_off in sysrq-o 2005-07-26 14:35:43 -07:00
process.c [PATCH] Fix suspend with traced tasks 2006-03-31 12:18:50 -08:00
smp.c [PATCH] Check if cpu can be onlined before calling smp_prepare_cpu() 2006-03-25 08:23:01 -08:00
snapshot.c [PATCH] swsusp: prevent possible image corruption on resume 2006-04-19 09:13:49 -07:00
swap.c [PATCH] swswsup: return correct load_image error 2006-03-26 08:56:55 -08:00
swsusp.c [PATCH] swsusp: rework memory shrinker 2006-06-23 07:42:48 -07:00
user.c [PATCH] swsusp: add s2ram ioctl to userland interface 2006-03-23 07:38:08 -08:00