[Devel] Re: [PATCH 1/2] memcg: dirty pages accounting and limiting infrastructure

Balbir Singh balbir at linux.vnet.ibm.com
Mon Feb 22 09:29:38 PST 2010


* Vivek Goyal <vgoyal at redhat.com> [2010-02-22 10:58:40]:

> 
> We seem to be doing same operation as existing "mem_cgroup_update_file_mapped"
> function is doing to udpate some stats. Can we just reuse that? We
> probably can create one core function which take index of stat to update
> and update_file_mapped and other variants for memcg dirty ratio can make
> use of it.
>

Good Point, it can be easily extended to be generic
 
> In fact instead of single function charge_dirty() accounting for
> WRITEBACK, we well as other states like UNSTABLE_NFS is not very intutive.
> May be we can have indivdual functions.
> 
> mem_cgroup_update_dirty()
> mem_cgroup_update_writeback()
> mem_cgroup_update_unstable_nfs() etc.
>

Hmm.. probably yes. 

-- 
	Three Cheers,
	Balbir
_______________________________________________
Containers mailing list
Containers at lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/containers




More information about the Devel mailing list