Hi Michal, [sorry for the delay, I was traveling with no connectivity] On Mon, Jun 27, 2016 at 03:05:28PM +0200, Michal Hocko wrote: > On Fri 24-06-16 13:51:01, Johannes Weiner wrote: > > Acked-by: Michal Hocko <mhocko@xxxxxxxx> Thanks! > Minor note below > > > +static inline struct mem_cgroup *page_memcg_rcu(struct page *page) > > +{ > > I guess rcu_read_lock_held() here would be appropriate > > > + return READ_ONCE(page->mem_cgroup); Agreed. Andrew, could you please fold this? >From ed49e364e47c933d84533a0d8bd355831b5ca9f1 Mon Sep 17 00:00:00 2001 From: Johannes Weiner <hannes@xxxxxxxxxxx> Date: Thu, 7 Jul 2016 15:38:26 -0400 Subject: [PATCH] mm: fix vm-scalability regression in cgroup-aware workingset code fix Signed-off-by: Johannes Weiner <hannes@xxxxxxxxxxx> --- include/linux/mm.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/linux/mm.h b/include/linux/mm.h index b21e5f30378e..97065e1f0237 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h @@ -975,6 +975,7 @@ static inline struct mem_cgroup *page_memcg(struct page *page) } static inline struct mem_cgroup *page_memcg_rcu(struct page *page) { + WARN_ON_ONCE(!rcu_read_lock_held()); return READ_ONCE(page->mem_cgroup); } #else @@ -984,6 +985,7 @@ static inline struct mem_cgroup *page_memcg(struct page *page) } static inline struct mem_cgroup *page_memcg_rcu(struct page *page) { + WARN_ON_ONCE(!rcu_read_lock_held()); return NULL; } #endif -- 2.9.0 -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxx. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a>