Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=c75fd0ee6e1750e6e527ed1d4aeee66739d9ad79
Commit:     c75fd0ee6e1750e6e527ed1d4aeee66739d9ad79
Parent:     418106d6248618bca1add65168a82974c72206db
Author:     Rafael J. Wysocki <[EMAIL PROTECTED]>
AuthorDate: Wed Apr 4 19:08:21 2007 -0700
Committer:  Linus Torvalds <[EMAIL PROTECTED]>
CommitDate: Wed Apr 4 21:12:47 2007 -0700

    [PATCH] swsusp: fix memory shrinker
    
    Fix a bug in the swsusp's memory shrinker that causes some systems using
    highmem to refuse to suspend to disk if image_size is set above 1/2 of
    available RAM.
    
    Special thanks to Jiri Slaby for reporting the problem and assistance in
    debugging it.
    
    Signed-off-by: Rafael J. Wysocki <[EMAIL PROTECTED]>
    Cc: Jiri Slaby <[EMAIL PROTECTED]>
    Cc: Pavel Machek <[EMAIL PROTECTED]>
    Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
    Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>
---
 kernel/power/swsusp.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/kernel/power/swsusp.c b/kernel/power/swsusp.c
index 7fb8343..1753708 100644
--- a/kernel/power/swsusp.c
+++ b/kernel/power/swsusp.c
@@ -229,13 +229,13 @@ int swsusp_shrink_memory(void)
                size += highmem_size;
                for_each_zone (zone)
                        if (populated_zone(zone)) {
+                               tmp += snapshot_additional_pages(zone);
                                if (is_highmem(zone)) {
                                        highmem_size -=
                                        zone_page_state(zone, NR_FREE_PAGES);
                                } else {
                                        tmp -= zone_page_state(zone, 
NR_FREE_PAGES);
                                        tmp += 
zone->lowmem_reserve[ZONE_NORMAL];
-                                       tmp += snapshot_additional_pages(zone);
                                }
                        }
 
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to