From: Alexander Nyberg <alexn@dsv.su.se>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: linux-kernel@vger.kernel.org, cw@f00f.org, andre@cachola.com.br,
Andrew Morton <akpm@osdl.org>
Subject: Re: A patch for the file kernel/fork.c
Date: Thu, 05 May 2005 17:32:56 +0200 [thread overview]
Message-ID: <1115307176.3993.9.camel@localhost.localdomain> (raw)
In-Reply-To: <1115300887.21180.14.camel@localhost.localdomain>
> Instead of the for(;;) msleep, why not just take it permanently off the
> run queue? With the following:
>
> set_current_state(TASK_UNINTERRUPTIBLE);
> schedule();
>
> It basically gives the same effect, but is cleaner.
Ah perfect, now it looks ok. Thanks!
Prevent recursive faults in do_exit() by leaving the task alone and wait
for reboot. This may allow a more graceful shutdown and possibly save
the original oops.
Signed-off-by: Alexander Nyberg <alexn@telia.com>
Index: mm/kernel/exit.c
===================================================================
--- mm.orig/kernel/exit.c 2005-05-05 16:44:20.000000000 +0200
+++ mm/kernel/exit.c 2005-05-05 17:29:40.000000000 +0200
@@ -797,6 +797,14 @@
ptrace_notify((PTRACE_EVENT_EXIT << 8) | SIGTRAP);
}
+ /* We're taking recursive faults here in do_exit. Safest
+ * is to just leave this task alone and wait for reboot. */
+ if (unlikely(tsk->flags & PF_EXITING)) {
+ printk(KERN_ALERT "\nFixing recursive fault but reboot is needed!\n");
+ set_current_state(TASK_UNINTERRUPTIBLE);
+ schedule();
+ }
+
tsk->flags |= PF_EXITING;
/*
next prev parent reply other threads:[~2005-05-05 15:33 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-05-04 14:46 A patch for the file kernel/fork.c André Pereira de Almeida
2005-05-04 17:54 ` Chris Wedgwood
2005-05-04 18:26 ` André Pereira de Almeida
2005-05-04 18:43 ` Chris Wedgwood
2005-05-04 19:04 ` André Pereira de Almeida
2005-05-04 19:16 ` Alexander Nyberg
2005-05-04 19:41 ` Andrew Morton
2005-05-04 20:54 ` André Pereira de Almeida
2005-05-04 21:21 ` Alexander Nyberg
2005-05-05 13:48 ` Steven Rostedt
2005-05-05 15:32 ` Alexander Nyberg [this message]
2005-05-07 1:08 ` Andrew Morton
2005-05-04 19:11 ` Valdis.Kletnieks
2005-05-04 19:34 ` Dmitry Torokhov
2005-05-04 19:35 ` André Pereira de Almeida
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1115307176.3993.9.camel@localhost.localdomain \
--to=alexn@dsv.su.se \
--cc=akpm@osdl.org \
--cc=andre@cachola.com.br \
--cc=cw@f00f.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rostedt@goodmis.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox