[PATCH] Use ZVC for free_pages
This is again simplifies some of the VM counter calculations through the use of the ZVC consolidated counters. [michal.k.k.piotrowski@gmail.com: build fix] Signed-off-by: Christoph Lameter <clameter@sgi.com> Signed-off-by: Michal Piotrowski <michal.k.k.piotrowski@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:

committed by
Linus Torvalds

parent
c878538598
commit
d23ad42324
@@ -230,9 +230,10 @@ int swsusp_shrink_memory(void)
|
||||
for_each_zone (zone)
|
||||
if (populated_zone(zone)) {
|
||||
if (is_highmem(zone)) {
|
||||
highmem_size -= zone->free_pages;
|
||||
highmem_size -=
|
||||
zone_page_state(zone, NR_FREE_PAGES);
|
||||
} else {
|
||||
tmp -= zone->free_pages;
|
||||
tmp -= zone_page_state(zone, NR_FREE_PAGES);
|
||||
tmp += zone->lowmem_reserve[ZONE_NORMAL];
|
||||
tmp += snapshot_additional_pages(zone);
|
||||
}
|
||||
|
Reference in New Issue
Block a user