Re: Accounting problem of MIGRATE_ISOLATED freed page
From: KOSAKI Motohiro
Date: Thu Jun 21 2012 - 13:22:55 EST
>
> Hm. I'm sorry if I couldn't chase the disucussion...Can I make summary ?
>
> As you shown, it seems to be not difficult to counting free pages under
> MIGRATE_ISOLATE.
> And we can know the zone contains MIGRATE_ISOLATE area or not by simple
> check.
> for example.
> ==
> set_pageblock_migratetype(page, MIGRATE_ISOLATE);
> move_freepages_block(zone, page, MIGRATE_ISOLATE);
> zone->nr_isolated_areas++;
> =
>
> Then, the solution will be adding a function like following
> =
> u64 zone_nr_free_pages(struct zone *zone) {
> unsigned long free_pages;
>
> free_pages = zone_page_state(NR_FREE_PAGES);
> if (unlikely(z->nr_isolated_areas)) {
> isolated = count_migrate_isolated_pages(zone);
> free_pages -= isolated;
> }
> return free_pages;
> }
> =
>
> Right ?
This represent my intention exactly. :)
> and... zone->all_unreclaimable is a different problem ?
Yes, all_unreclaimable derived livelock don't depend on memory hotplug.
--
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/