From: Oleg Nesterov Date: Mon, 14 Mar 2011 19:05:30 +0000 (+0100) Subject: oom: oom_kill_process: fix the child_points logic X-Git-Tag: v2.6.38~5 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dc1b83ab08f1954335692cdcd499f78c94f4c42a;p=pandora-kernel.git oom: oom_kill_process: fix the child_points logic oom_kill_process() starts with victim_points == 0. This means that (most likely) any child has more points and can be killed erroneously. Also, "children has a different mm" doesn't match the reality, we should check child->mm != t->mm. This check is not exactly correct if t->mm == NULL but this doesn't really matter, oom_kill_task() will kill them anyway. Note: "Kill all processes sharing p->mm" in oom_kill_task() is wrong too. Signed-off-by: Oleg Nesterov Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed