Re: [RFC][PATCH] memcg: fix swap account (26/May)[0/5]

From: KAMEZAWA Hiroyuki
Date: Wed May 27 2009 - 02:45:19 EST

On Tue, 26 May 2009 12:12:59 +0900
KAMEZAWA Hiroyuki <kamezawa.hiroyu@xxxxxxxxxxxxxx> wrote:

> [1/5] change interface of swap_duplicate()/swap_free()
> Adds an function swapcache_prepare() and swapcache_free().
> [2/5] add SWAP_HAS_CACHE flag to swap_map
> Add SWAP_HAS_CACHE flag to swap_map array for knowing an information that
> "there is an only swap cache and swap has no reference"
> without calling find_get_page().
> [3/5] Count the number of swap-cache-only swaps
> After repeating swap-in/out, there are tons of cache-only swaps.
> (via a mapped swapcache under vm_swap_full()==false)
> This patch counts the number of entry and show it in debug information.
> (for example, sysrq-m)
> [4/5] fix memcg's swap accounting.
> change the memcg's swap accounting logic to see # of references to swap.
> [5/5] experimental garbage collection for cache-only swaps.
> reclaim swap enty which is not used.

Thank you for all reviews. I'll repost when new mmotm comes.
[1/5] ... nochage
[2/5] ... fix the bug Nishimura-san pointed out
[3/5] ... drop
[4/5] ... no change
[5/5] ... will use direct reclaim in get_swap_page().


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at