Re: Large slab cache in 2.6.1

From: Andrew Morton
Date: Sun Feb 22 2004 - 01:11:10 EST


Nick Piggin <piggin@xxxxxxxxxxxxxxx> wrote:
>
> Although, nr_used_zone_pages probably shouldn't be counting
> highmem zones, which might be our problem.

yeah. We should have made that change when making shrink_slab() ignore
highmem scanning.

Something like this (the function needs a rename)

--- 25/mm/page_alloc.c~shrink_slab-highmem-fix 2004-02-21 22:07:32.000000000 -0800
+++ 25-akpm/mm/page_alloc.c 2004-02-21 22:08:03.000000000 -0800
@@ -769,8 +769,10 @@ unsigned int nr_used_zone_pages(void)
unsigned int pages = 0;
struct zone *zone;

- for_each_zone(zone)
- pages += zone->nr_active + zone->nr_inactive;
+ for_each_zone(zone) {
+ if (zone - zone->zone_pgdat->node_zones < ZONE_HIGHMEM)
+ pages += zone->nr_active + zone->nr_inactive;
+ }

return pages;
}

_

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/