In a stock 2.6.22.6 kernel, poweroff a user mode linux guest
(2.6.22.6 running in skas0 mode) will halt the host linux. I
think the reason is the kernel thread abort because of a bug.
Then the sys_reboot in process of user mode linux guest is
not trapped by the user mode linux kernel and is executed by host.
  I think it is better to make sure all of our children process
to quit when user mode linux kernel abort.

Signed-off-by: Lepton Wu <[EMAIL PROTECTED]>

diff -X linux-2.6.22.6/Documentation/dontdiff -pru 
linux-2.6.22.6/arch/um/os-Linux/util.c 
linux-2.6.22.6-lepton/arch/um/os-Linux/util.c
--- linux-2.6.22.6/arch/um/os-Linux/util.c      2007-09-14 17:41:10.000000000 
+0800
+++ linux-2.6.22.6-lepton/arch/um/os-Linux/util.c       2007-09-22 
13:56:05.000000000 +0800
@@ -106,5 +106,6 @@ int setjmp_wrapper(void (*proc)(void *, 
 void os_dump_core(void)
 {
        signal(SIGSEGV, SIG_DFL);
+       kill(0, SIGTERM);
        abort();
 }
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to