From: David Rientjes Date: Tue, 10 Aug 2010 00:18:57 +0000 (-0700) Subject: oom: remove unnecessary code and cleanup X-Git-Tag: v2.6.36-rc1~451 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b940fd703572f7f9e5f894c682c91c3cbd84c11e;p=pandora-kernel.git oom: remove unnecessary code and cleanup Remove the redundancy in __oom_kill_task() since: - init can never be passed to this function: it will never be PF_EXITING or selectable from select_bad_process(), and - it will never be passed a task from oom_kill_task() without an ->mm and we're unconcerned about detachment from exiting tasks, there's no reason to protect them against SIGKILL or access to memory reserves. Also moves the kernel log message to a higher level since the verbosity is not always emitted here; we need not print an error message if an exiting task is given a longer timeslice. __oom_kill_task() only has a single caller, so it can be merged into that function at the same time. Signed-off-by: David Rientjes Reviewed-by: KAMEZAWA Hiroyuki Cc: KAMEZAWA Hiroyuki Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed