From: Anton Vorontsov Date: Tue, 7 Feb 2012 06:49:51 +0000 (+0400) Subject: sysrq: Properly check for kernel threads X-Git-Tag: v3.4-rc1~185^2~112^2~2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d3a532a9c617106a0169232d40164ee35d0440b5;p=pandora-kernel.git sysrq: Properly check for kernel threads There's a real possibility of killing kernel threads that might have issued use_mm(), so kthread's mm might become non-NULL. This patch fixes the issue by checking for PF_KTHREAD (just as get_task_mm()). Suggested-by: Oleg Nesterov Signed-off-by: Anton Vorontsov Acked-by: David Rientjes Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed