X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=mm%2Foom_kill.c;h=626303b52f3ce0764d3bb1029f6bce8b5bcaa896;hb=22be504aaa4a3133d81e3fb0c4287960aea19c37;hp=eafff89b3dd634e8836842005695c1ad48cc0cb2;hpb=62c9072bee2272232d0ed92dc8148c48c1f10f8e;p=deliverable%2Flinux.git diff --git a/mm/oom_kill.c b/mm/oom_kill.c index eafff89b3dd6..626303b52f3c 100644 --- a/mm/oom_kill.c +++ b/mm/oom_kill.c @@ -303,7 +303,7 @@ static struct task_struct *select_bad_process(unsigned int *ppoints, do_each_thread(g, p) { unsigned int points; - if (!p->mm) + if (p->exit_state) continue; if (oom_unkillable_task(p, mem, nodemask)) continue; @@ -319,6 +319,8 @@ static struct task_struct *select_bad_process(unsigned int *ppoints, */ if (test_tsk_thread_flag(p, TIF_MEMDIE)) return ERR_PTR(-1UL); + if (!p->mm) + continue; if (p->flags & PF_EXITING) { /*