projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
284f39a
)
memcg: remove unnecessary !mm check from try_get_mem_cgroup_from_mm()
author
Johannes Weiner
<
[email protected]
>
Mon, 7 Apr 2014 22:37:42 +0000
(15:37 -0700)
committer
Linus Torvalds
<
[email protected]
>
Mon, 7 Apr 2014 23:35:56 +0000
(16:35 -0700)
Users pass either a mm that has been established under task lock, or use
a verified current->mm, which means the task can't be exiting.
Signed-off-by: Johannes Weiner <
[email protected]
>
Acked-by: Michal Hocko <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
mm/memcontrol.c
patch
|
blob
|
history
diff --git
a/mm/memcontrol.c
b/mm/memcontrol.c
index 8d6cedd16f8dfca39cf07d7c764b5bbd102d81f2..c3b674f9774f317e8188dbaaedfb7cbb8c8c4058 100644
(file)
--- a/
mm/memcontrol.c
+++ b/
mm/memcontrol.c
@@
-1075,13
+1075,6
@@
struct mem_cgroup *try_get_mem_cgroup_from_mm(struct mm_struct *mm)
{
struct mem_cgroup *memcg = NULL;
- if (!mm)
- return NULL;
- /*
- * Because we have no locks, mm->owner's may be being moved to other
- * cgroup. We use css_tryget() here even if this looks
- * pessimistic (rather than adding locks here).
- */
rcu_read_lock();
do {
memcg = mem_cgroup_from_task(rcu_dereference(mm->owner));