On Tue, 2 Mar 2010 09:01:58 +0100 Andrea Righi <arighi@develer.com> wrote:My concern is - migration between memcg is already suppoted - at task move - at rmdir Then, if you leave DIRTY_PAGE accounting to original cgroup, the new cgroup (migration target)'s Dirty page accounting may goes to be negative, or incorrect value. Please check FILE_MAPPED implementation in __mem_cgroup_move_account() As if (page_mapped(page) && !PageAnon(page)) { /* Update mapped_file data for mem_cgroup */ preempt_disable(); __this_cpu_dec(from->stat->count[MEM_CGROUP_STAT_FILE_MAPPED]); __this_cpu_inc(to->stat->count[MEM_CGROUP_STAT_FILE_MAPPED]); preempt_enable(); } then, FILE_MAPPED never goes negative. Thanks, -Kame --
