On Thu, 2007-08-30 at 21:44 -0700, Linus Torvalds wrote:
AFAICT, a corrupt stack could lead us to touch a page which isn't
mapped. If we assume the stack isn't corrupt, we don't have to do the
valid_stack_ptr() check at all...
head.S pushes a "$0" on the stack to stop the unwinder, lguest doesn't.
Here's the lguest fix, but I still think the real fix posted previously
is more important.
Cheers,
Rusty.
===
lguest doesn't terminate stack, upsets unwinder
Copy head.S, which puts a 0 on the stack to terminate ebp-chasing
backtrace code.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
diff -r 926e5cc964fd drivers/lguest/lguest_asm.S
--- a/drivers/lguest/lguest_asm.S Fri Aug 31 08:02:08 2007 +1000
+++ b/drivers/lguest/lguest_asm.S Fri Aug 31 16:01:25 2007 +1000
@@ -19,6 +19,8 @@
movl $(init_thread_union+THREAD_SIZE),%esp
movl %esi, %eax
addl $__PAGE_OFFSET, %eax
+ /* Fake value to stop backtraces with CONFIG_FRAME_POINTER */
+ pushl $0
jmp lguest_init
/*G:055 We create a macro which puts the assembler code between lgstart_ and
-