From: Paul Mackerras Date: Mon, 19 Feb 2007 00:42:42 +0000 (+1100) Subject: [POWERPC] Harden validate_sp against stack corruption X-Git-Tag: v2.6.22-rc1~1109^2~212 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bb72c481e970dc1b4034ddccbe8302ff39e0d948;p=pandora-kernel.git [POWERPC] Harden validate_sp against stack corruption If something has overflowed or corrupted the stack and causes an oops, and we try to print a stack trace, that will call validate_sp, which can itself cause an oops if the cpu field of the thread_info struct at the bottom of the stack has been corrupted (if CONFIG_IRQSTACKS is set). This makes debugging harder. To avoid the second oops, this adds a check to make sure that the cpu number is reasonable before using it to check whether the stack is on the softirq or hardirq stack. Signed-off-by: Paul Mackerras --- Reading git-diff-tree failed