]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
mm: move memcg hierarchy reclaim to generic reclaim code
authorJohannes Weiner <jweiner@redhat.com>
Fri, 16 Dec 2011 04:50:32 +0000 (15:50 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 20 Dec 2011 07:43:58 +0000 (18:43 +1100)
commit7748fe2234c527c0e665dde604aac9cf34cf1ec4
tree31006fe7fdfd69d09da1a758c0a3d44ad006bb6e
parent0eee48ace9389eb8c18ffdfbc7badf1fad913d3a
mm: move memcg hierarchy reclaim to generic reclaim code

Memory cgroup limit reclaim and traditional global pressure reclaim will
soon share the same code to reclaim from a hierarchical tree of memory
cgroups.

In preparation of this, move the two right next to each other in
shrink_zone().

The mem_cgroup_hierarchical_reclaim() polymath is split into a soft limit
reclaim function, which still does hierarchy walking on its own, and a
limit (shrinking) reclaim function, which relies on generic reclaim code
to walk the hierarchy.

Signed-off-by: Johannes Weiner <jweiner@redhat.com>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Reviewed-by: Michal Hocko <mhocko@suse.cz>
Reviewed-by: Kirill A. Shutemov <kirill@shutemov.name>
Cc: Daisuke Nishimura <nishimura@mxp.nes.nec.co.jp>
Cc: Balbir Singh <bsingharora@gmail.com>
Cc: Ying Han <yinghan@google.com>
Cc: Greg Thelen <gthelen@google.com>
Cc: Michel Lespinasse <walken@google.com>
Cc: Rik van Riel <riel@redhat.com>
Cc: Minchan Kim <minchan.kim@gmail.com>
Cc: Christoph Hellwig <hch@infradead.org>
Cc: Hugh Dickins <hughd@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
include/linux/memcontrol.h
mm/memcontrol.c
mm/vmscan.c