On Wed, 20 Oct 2010 23:35:15 +0900
Minchan Kim <[email protected]> wrote:

> On Wed, Oct 20, 2010 at 02:02:55PM +0900, KAMEZAWA Hiroyuki wrote:
> > Fixed one here.
> > ==
> > From: KAMEZAWA Hiroyuki <[email protected]>
> > 
> > Now, at calculating dirty limit, vm_dirty_param() is called.
> > This function returns dirty-limit related parameters considering
> > memory cgroup settings.
> > 
> > Now, assume that vm_dirty_bytes=100M (global dirty limit) and
> > memory cgroup has 1G of pages and 40 dirty_ratio, dirtyable memory is
> > 500MB.
> > 
> > In this case, global_dirty_limits will consider dirty_limt as
> > 500 *0.4 = 200MB. This is bad...memory cgroup is not back door.
> > 
> > This patch limits the return value of vm_dirty_param() considring
> > global settings.
> > 
> > Changelog:
> >  - fixed an argument "mem" int to u64
> >  - fixed to use global available memory to cap memcg's value.
> > 
> > Signed-off-by: KAMEZAWA Hiroyuki <[email protected]>
> Reviewed-by: Minchan Kim <[email protected]>
> 
> It should have written this on Documentation.
> "memcg dirty limit can't exceed global dirty limit"
> 
Sure. Anyway we need review & rewrite Documenation after dirty limit
merged. (I think Greg will do much.)

Thanks,
-Kame

_______________________________________________
Containers mailing list
[email protected]
https://lists.linux-foundation.org/mailman/listinfo/containers

_______________________________________________
Devel mailing list
[email protected]
https://openvz.org/mailman/listinfo/devel

Reply via email to