linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [patch] memcg: charged pages always have valid per-memcg zone info
@ 2011-02-09 10:44 Johannes Weiner
  2011-02-09 23:42 ` KAMEZAWA Hiroyuki
  2011-02-10  2:36 ` Minchan Kim
  0 siblings, 2 replies; 3+ messages in thread
From: Johannes Weiner @ 2011-02-09 10:44 UTC (permalink / raw)
  To: Andrew Morton
  Cc: KAMEZAWA Hiroyuki, Daisuke Nishimura, Balbir Singh, linux-mm,
	linux-kernel

page_cgroup_zoneinfo() will never return NULL for a charged page,
remove the check for it in mem_cgroup_get_reclaim_stat_from_page().

Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
---
 mm/memcontrol.c |    3 ---
 1 files changed, 0 insertions(+), 3 deletions(-)

Andrew, this is a follow-up to 'memcg: no uncharged pages reach
page_cgroup_zoneinfo'.

diff --git a/mm/memcontrol.c b/mm/memcontrol.c
index 686f1ce..6d007d6 100644
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@ -1017,9 +1017,6 @@ mem_cgroup_get_reclaim_stat_from_page(struct page *page)
 	/* Ensure pc->mem_cgroup is visible after reading PCG_USED. */
 	smp_rmb();
 	mz = page_cgroup_zoneinfo(pc->mem_cgroup, page);
-	if (!mz)
-		return NULL;
-
 	return &mz->reclaim_stat;
 }
 
-- 
1.7.4

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [patch] memcg: charged pages always have valid per-memcg zone info
  2011-02-09 10:44 [patch] memcg: charged pages always have valid per-memcg zone info Johannes Weiner
@ 2011-02-09 23:42 ` KAMEZAWA Hiroyuki
  2011-02-10  2:36 ` Minchan Kim
  1 sibling, 0 replies; 3+ messages in thread
From: KAMEZAWA Hiroyuki @ 2011-02-09 23:42 UTC (permalink / raw)
  To: Johannes Weiner
  Cc: Andrew Morton, Daisuke Nishimura, Balbir Singh, linux-mm,
	linux-kernel

On Wed,  9 Feb 2011 11:44:35 +0100
Johannes Weiner <hannes@cmpxchg.org> wrote:

> page_cgroup_zoneinfo() will never return NULL for a charged page,
> remove the check for it in mem_cgroup_get_reclaim_stat_from_page().
> 
> Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>

IIUC, this _was_ required when force_empty() had troubles.
But now, not required.

Acked-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [patch] memcg: charged pages always have valid per-memcg zone info
  2011-02-09 10:44 [patch] memcg: charged pages always have valid per-memcg zone info Johannes Weiner
  2011-02-09 23:42 ` KAMEZAWA Hiroyuki
@ 2011-02-10  2:36 ` Minchan Kim
  1 sibling, 0 replies; 3+ messages in thread
From: Minchan Kim @ 2011-02-10  2:36 UTC (permalink / raw)
  To: Johannes Weiner
  Cc: Andrew Morton, KAMEZAWA Hiroyuki, Daisuke Nishimura, Balbir Singh,
	linux-mm, linux-kernel

On Wed, Feb 9, 2011 at 7:44 PM, Johannes Weiner <hannes@cmpxchg.org> wrote:
> page_cgroup_zoneinfo() will never return NULL for a charged page,
> remove the check for it in mem_cgroup_get_reclaim_stat_from_page().
>
> Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
Reviewed-by: Minchan Kim <minchan.kim@gmail.com>

-- 
Kind regards,
Minchan Kim

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-02-10  2:36 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-02-09 10:44 [patch] memcg: charged pages always have valid per-memcg zone info Johannes Weiner
2011-02-09 23:42 ` KAMEZAWA Hiroyuki
2011-02-10  2:36 ` Minchan Kim

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).