Re: Pull request: TASK_KILLABLE

From: Trond Myklebust
Date: Thu Jan 31 2008 - 20:45:47 EST



On Fri, 2008-02-01 at 11:48 +1100, Linus Torvalds wrote:
>
> On Thu, 31 Jan 2008, Matthew Wilcox wrote:
> >
> > To allow tasks to be interrupted by fatal signals, we introduce a new
> > TASK_* bit; TASK_WAKEKILL. We also add a predicate fatal_signal_pending;
> > the counterpart of signal_pending(). Then we add killable versions
> > of lock_page(), mutex_lock(), schedule_timeout(), wait_event(), and
> > wait_for_completion(). Finally, we can make the NFS 'intr' mount option
> > a no-op.
>
> Ok, I've pulled this. It conflicted with some NFS changes, but I did what
> appeared to be the obvious conflict resolution, and it all at least
> compiles and it looked sane to me. But I don't have NFS enabled normally,
> and I certainly don't have a good way to test with my laptop while in
> Melbourne, so Trond/Matthew, can you please double- and triple-check my
> merge?

Hmm... The current code won't compile as a module. We're at least going
to require something like the attached patch.

Cheers
Trond
--- Begin Message --- It may be used by the modules nfs.ko and sunrpc.ko

Signed-off-by: Trond Myklebust <Trond.Myklebust@xxxxxxxxxx>
---

kernel/signal.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/kernel/signal.c b/kernel/signal.c
index 8054dd4..1f2d4e1 100644
--- a/kernel/signal.c
+++ b/kernel/signal.c
@@ -998,6 +998,7 @@ int fastcall __fatal_signal_pending(struct task_struct *tsk)
{
return sigismember(&tsk->pending.signal, SIGKILL);
}
+EXPORT_SYMBOL_GPL(__fatal_signal_pending);

/*
* Must be called under rcu_read_lock() or with tasklist_lock read-held.

--- End Message ---