diff options
| author | Dave Jones <davej@suse.de> | 2002-04-02 19:21:59 -0800 |
|---|---|---|
| committer | Dave Jones <davej@suse.de> | 2002-04-02 19:21:59 -0800 |
| commit | dc11908a3257d13f23b1f13fbba01aa69e71bb1b (patch) | |
| tree | 0b36c781cc17b1b37cf5ddbb1933f7635c50f67e /fs/proc/array.c | |
| parent | 4e7e186576a28e12e0cf22c87b89e102b581af56 (diff) | |
[PATCH] proc race on task_struct->sig
Originally from Chris Mason <mason@suse.com>..
collect_sigign_sigcatch can race against exit_sighand. I haven't been
able to reproduce it, but I think it causes the oops reported in the
'Kernel Hangs 2.4.16 on heavy io Oracle Tivolie TSM' thread.
Diffstat (limited to 'fs/proc/array.c')
| -rw-r--r-- | fs/proc/array.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/proc/array.c b/fs/proc/array.c index d216d47ddcdc..28c6a3d4a3ef 100644 --- a/fs/proc/array.c +++ b/fs/proc/array.c @@ -227,6 +227,7 @@ static void collect_sigign_sigcatch(struct task_struct *p, sigset_t *ign, sigemptyset(ign); sigemptyset(catch); + spin_lock_irq(&p->sigmask_lock); if (p->sig) { k = p->sig->action; for (i = 1; i <= _NSIG; ++i, ++k) { @@ -236,6 +237,7 @@ static void collect_sigign_sigcatch(struct task_struct *p, sigset_t *ign, sigaddset(catch, i); } } + spin_unlock_irq(&p->sigmask_lock); } static inline char * task_sig(struct task_struct *p, char *buffer) |
