From: David S. Miller Date: Fri, 29 Feb 2008 04:38:15 +0000 (-0800) Subject: [SPARC64]: Adjust kernel PC validation test in fault handler. X-Git-Tag: v2.6.25-rc4~149^2 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=be71716e464f4ea38f08034dc666f2feb55535d9;p=linux-2.6 [SPARC64]: Adjust kernel PC validation test in fault handler. Because of the new futex validation init handler, we have to accept faults in init section text as well as the normal kernel text. Thanks to Tom Callaway for the bug report. Signed-off-by: David S. Miller --- diff --git a/arch/sparc64/mm/fault.c b/arch/sparc64/mm/fault.c index 9183633602..2650d0d33a 100644 --- a/arch/sparc64/mm/fault.c +++ b/arch/sparc64/mm/fault.c @@ -286,7 +286,7 @@ asmlinkage void __kprobes do_sparc64_fault(struct pt_regs *regs) unsigned long tpc = regs->tpc; /* Sanity check the PC. */ - if ((tpc >= KERNBASE && tpc < (unsigned long) _etext) || + if ((tpc >= KERNBASE && tpc < (unsigned long) __init_end) || (tpc >= MODULES_VADDR && tpc < MODULES_END)) { /* Valid, no problems... */ } else {