* [BUGFIX][PATCH] memcg: use rcu_dereference to access mm->owner
@ 2009-04-13 6:43 KAMEZAWA Hiroyuki
2009-04-14 16:04 ` Balbir Singh
0 siblings, 1 reply; 2+ messages in thread
From: KAMEZAWA Hiroyuki @ 2009-04-13 6:43 UTC (permalink / raw)
To: linux-kernel; +Cc: akpm, balbir, nishimura, kosaki.motohiro
the patch itself is against mmotm-Apr11.
Maybe it's better to apply 2.6.30-rc series.
==
From: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
mm->owner should be accessed with rcu_dereference().
Reported-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
---
include/linux/memcontrol.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: mmotm-2.6.30-Apr11/include/linux/memcontrol.h
===================================================================
--- mmotm-2.6.30-Apr11.orig/include/linux/memcontrol.h
+++ mmotm-2.6.30-Apr11/include/linux/memcontrol.h
@@ -75,7 +75,7 @@ int mm_match_cgroup(const struct mm_stru
{
struct mem_cgroup *mem;
rcu_read_lock();
- mem = mem_cgroup_from_task((mm)->owner);
+ mem = mem_cgroup_from_task(rcu_dereference((mm)->owner));
rcu_read_unlock();
return cgroup == mem;
}
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [BUGFIX][PATCH] memcg: use rcu_dereference to access mm->owner
2009-04-13 6:43 [BUGFIX][PATCH] memcg: use rcu_dereference to access mm->owner KAMEZAWA Hiroyuki
@ 2009-04-14 16:04 ` Balbir Singh
0 siblings, 0 replies; 2+ messages in thread
From: Balbir Singh @ 2009-04-14 16:04 UTC (permalink / raw)
To: KAMEZAWA Hiroyuki; +Cc: linux-kernel, akpm, nishimura, kosaki.motohiro
* KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com> [2009-04-13 15:43:43]:
> the patch itself is against mmotm-Apr11.
> Maybe it's better to apply 2.6.30-rc series.
> ==
> From: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
>
> mm->owner should be accessed with rcu_dereference().
>
> Reported-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
> Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Acked-by: Balbir Singh <balbir@linux.vnet.ibm.com>
--
Balbir
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-04-14 16:05 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-04-13 6:43 [BUGFIX][PATCH] memcg: use rcu_dereference to access mm->owner KAMEZAWA Hiroyuki
2009-04-14 16:04 ` Balbir Singh
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®