Re: [PATCH 2/2] mm/memcontrol.c: introduce helper mem_cgroup_zoneinfo_zone()

2014-05-05 Thread Andrew Morton
On Fri, 2 May 2014 19:29:08 -0400 Johannes Weiner wrote: > Memcg zoneinfo lookup sites have either the page, the zone, or the > node id and zone index, but sites that only have the zone have to look > up the node id and zone index themselves, whereas sites that already > have those two integers u

Re: [PATCH 2/2] mm/memcontrol.c: introduce helper mem_cgroup_zoneinfo_zone()

2014-05-05 Thread Michal Hocko
On Fri 02-05-14 19:31:38, Johannes Weiner wrote: > While in that area, I noticed that the soft limit tree updaters don't > actually use the memcg argument anymore... > > --- > From: Johannes Weiner > Subject: [patch] mm: memcontrol: remove unnecessary memcg argument from soft > limit functions >

Re: [PATCH 2/2] mm/memcontrol.c: introduce helper mem_cgroup_zoneinfo_zone()

2014-05-05 Thread Michal Hocko
On Fri 02-05-14 19:29:08, Johannes Weiner wrote: [...] > From: Jianyu Zhan > Subject: [patch] mm: memcontrol: clean up memcg zoneinfo lookup > > Memcg zoneinfo lookup sites have either the page, the zone, or the > node id and zone index, but sites that only have the zone have to look > up the nod

Re: [PATCH 2/2] mm/memcontrol.c: introduce helper mem_cgroup_zoneinfo_zone()

2014-05-02 Thread Johannes Weiner
While in that area, I noticed that the soft limit tree updaters don't actually use the memcg argument anymore... --- From: Johannes Weiner Subject: [patch] mm: memcontrol: remove unnecessary memcg argument from soft limit functions Signed-off-by: Johannes Weiner --- mm/memcontrol.c | 34 +

Re: [PATCH 2/2] mm/memcontrol.c: introduce helper mem_cgroup_zoneinfo_zone()

2014-05-02 Thread Johannes Weiner
On Fri, May 02, 2014 at 03:05:16PM -0700, Andrew Morton wrote: > On Thu, 1 May 2014 08:54:50 -0400 Johannes Weiner wrote: > > > On Mon, Apr 28, 2014 at 05:04:26PM +0200, Michal Hocko wrote: > > > On Tue 22-04-14 11:59:23, Michal Hocko wrote: > > > > On Sat 19-04-14 07:01:43, Jianyu Zhan wrote: >

Re: [PATCH 2/2] mm/memcontrol.c: introduce helper mem_cgroup_zoneinfo_zone()

2014-05-02 Thread Andrew Morton
On Thu, 1 May 2014 08:54:50 -0400 Johannes Weiner wrote: > On Mon, Apr 28, 2014 at 05:04:26PM +0200, Michal Hocko wrote: > > On Tue 22-04-14 11:59:23, Michal Hocko wrote: > > > On Sat 19-04-14 07:01:43, Jianyu Zhan wrote: > > > > introduce helper mem_cgroup_zoneinfo_zone(). This will make > > > >

Re: [PATCH 2/2] mm/memcontrol.c: introduce helper mem_cgroup_zoneinfo_zone()

2014-05-01 Thread Johannes Weiner
[fix Andrew's email address] On Thu, May 01, 2014 at 08:54:50AM -0400, Johannes Weiner wrote: > On Mon, Apr 28, 2014 at 05:04:26PM +0200, Michal Hocko wrote: > > On Tue 22-04-14 11:59:23, Michal Hocko wrote: > > > On Sat 19-04-14 07:01:43, Jianyu Zhan wrote: > > > > introduce helper mem_cgroup_zon

Re: [PATCH 2/2] mm/memcontrol.c: introduce helper mem_cgroup_zoneinfo_zone()

2014-05-01 Thread Johannes Weiner
On Mon, Apr 28, 2014 at 05:04:26PM +0200, Michal Hocko wrote: > On Tue 22-04-14 11:59:23, Michal Hocko wrote: > > On Sat 19-04-14 07:01:43, Jianyu Zhan wrote: > > > introduce helper mem_cgroup_zoneinfo_zone(). This will make > > > mem_cgroup_iter() code more compact. > > > > I dunno. Helpers are u

Re: [PATCH 2/2] mm/memcontrol.c: introduce helper mem_cgroup_zoneinfo_zone()

2014-04-28 Thread Michal Hocko
On Tue 22-04-14 11:59:23, Michal Hocko wrote: > On Sat 19-04-14 07:01:43, Jianyu Zhan wrote: > > introduce helper mem_cgroup_zoneinfo_zone(). This will make > > mem_cgroup_iter() code more compact. > > I dunno. Helpers are usually nice but this one adds more code then it > removes. It also doesn't

Re: [PATCH 2/2] mm/memcontrol.c: introduce helper mem_cgroup_zoneinfo_zone()

2014-04-22 Thread Michal Hocko
On Sat 19-04-14 07:01:43, Jianyu Zhan wrote: > introduce helper mem_cgroup_zoneinfo_zone(). This will make > mem_cgroup_iter() code more compact. I dunno. Helpers are usually nice but this one adds more code then it removes. It also doesn't help the generated code. So I don't see any reason to me

[PATCH 2/2] mm/memcontrol.c: introduce helper mem_cgroup_zoneinfo_zone()

2014-04-18 Thread Jianyu Zhan
introduce helper mem_cgroup_zoneinfo_zone(). This will make mem_cgroup_iter() code more compact. Signed-off-by: Jianyu Zhan --- mm/memcontrol.c | 15 +++ 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/mm/memcontrol.c b/mm/memcontrol.c index e0ce15c..80d9e38 100644 ---