public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH] 2.6.22.6 user-mode linux: before abort, we make it sure all children quit
@ 2007-09-22  8:01 lepton
  2007-09-25 17:53 ` Jeff Dike
  0 siblings, 1 reply; 2+ messages in thread
From: lepton @ 2007-09-22  8:01 UTC (permalink / raw)
  To: jdike; +Cc: lkm

  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 <ytht.net@gmail.com>

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();
 }

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2007-09-25 17:53 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-09-22  8:01 [RFC PATCH] 2.6.22.6 user-mode linux: before abort, we make it sure all children quit lepton
2007-09-25 17:53 ` Jeff Dike

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox