From: David Rientjes Date: Tue, 26 Oct 2010 21:21:26 +0000 (-0700) Subject: oom: fix locking for oom_adj and oom_score_adj X-Git-Tag: v2.6.37-rc1~105^2~157 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d19d5476f4b9f91d2de92b91588bb118beba6c0d;p=pandora-kernel.git oom: fix locking for oom_adj and oom_score_adj The locking order in oom_adjust_write() and oom_score_adj_write() for task->alloc_lock and task->sighand->siglock is reversed, and lockdep notices that irqs could encounter an ABBA scenario. This fixes the locking order so that we always take task_lock(task) prior to lock_task_sighand(task). Signed-off-by: David Rientjes Reported-by: Andrew Morton Cc: KAMEZAWA Hiroyuki Cc: KOSAKI Motohiro Cc: Rik van Riel Cc: Ying Han Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed