KAMEZAWA Hiroyuki 747388d78a memcg: fix css_is_ancestor() RCU locking
Some callers (in memcontrol.c) calls css_is_ancestor() without
rcu_read_lock.  Because css_is_ancestor() has to access RCU protected
data, it should be under rcu_read_lock().

This makes css_is_ancestor() itself does safe access to RCU protected
area.  (At least, "root" can have refcnt==0 if it's not an ancestor of
"child".  So, we need rcu_read_lock().)

Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
Cc: Daisuke Nishimura <nishimura@mxp.nes.nec.co.jp>
Cc: Balbir Singh <balbir@linux.vnet.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-05-11 17:33:42 -07:00
..
2010-04-25 08:54:42 +02:00
2009-04-01 08:59:13 -07:00
2010-03-06 11:26:23 -08:00
2010-02-05 12:22:40 +01:00
2009-06-16 19:47:28 -07:00
2009-09-22 07:17:35 -07:00
2010-03-06 11:26:24 -08:00
2010-03-24 16:31:21 -07:00
2007-10-20 01:27:18 +02:00
2009-12-16 19:48:48 -05:00
2009-06-23 12:50:05 -07:00