From 014b1b8db6a786ec9f64a02e47b308f1267cc819 Mon Sep 17 00:00:00 2001 From: KOSAKI Motohiro Date: Mon, 21 Sep 2009 17:03:15 -0700 Subject: [PATCH] --- yaml --- r: 164461 b: refs/heads/master c: 8c5cd6f3a1721085652da204d454af4f8b92eda2 h: refs/heads/master i: 164459: 936b470af2e71e07d2078942c07c193c0d493448 v: v3 --- [refs] | 2 +- trunk/mm/oom_kill.c | 17 +---------------- 2 files changed, 2 insertions(+), 17 deletions(-) diff --git a/[refs] b/[refs] index 70af65a64c56..866cdb218e13 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 495789a51a91cb8c015d8d77fecbac1caf20b186 +refs/heads/master: 8c5cd6f3a1721085652da204d454af4f8b92eda2 diff --git a/trunk/mm/oom_kill.c b/trunk/mm/oom_kill.c index 372692294844..ea2147dabba6 100644 --- a/trunk/mm/oom_kill.c +++ b/trunk/mm/oom_kill.c @@ -373,11 +373,6 @@ static void __oom_kill_task(struct task_struct *p, int verbose) static int oom_kill_task(struct task_struct *p) { - struct mm_struct *mm; - struct task_struct *g, *q; - - mm = p->mm; - /* WARNING: mm may not be dereferenced since we did not obtain its * value from get_task_mm(p). This is OK since all we need to do is * compare mm to q->mm below. @@ -386,21 +381,11 @@ static int oom_kill_task(struct task_struct *p) * change to NULL at any time since we do not hold task_lock(p). * However, this is of no concern to us. */ - if (!mm || p->signal->oom_adj == OOM_DISABLE) + if (!p->mm || p->signal->oom_adj == OOM_DISABLE) return 1; __oom_kill_task(p, 1); - /* - * kill all processes that share the ->mm (i.e. all threads), - * but are in a different thread group. Don't let them have access - * to memory reserves though, otherwise we might deplete all memory. - */ - do_each_thread(g, q) { - if (q->mm == mm && !same_thread_group(q, p)) - force_sig(SIGKILL, q); - } while_each_thread(g, q); - return 0; }