* PATCH: Stop the tty vanishing under procfs access
@ 2006-08-16 16:33 Alan Cox
0 siblings, 0 replies; only message in thread
From: Alan Cox @ 2006-08-16 16:33 UTC (permalink / raw)
To: akpm, linux-kernel
Would appreciate people double checking this one.
Signed-off-by: Alan Cox <alan@redhat.com>
diff -u --new-file --recursive --exclude-from /usr/src/exclude linux.vanilla-2.6.18-rc4-mm1/fs/proc/array.c linux-2.6.18-rc4-mm1/fs/proc/array.c
--- linux.vanilla-2.6.18-rc4-mm1/fs/proc/array.c 2006-08-15 15:39:31.000000000 +0100
+++ linux-2.6.18-rc4-mm1/fs/proc/array.c 2006-08-15 16:02:56.000000000 +0100
@@ -347,6 +347,8 @@
sigemptyset(&sigign);
sigemptyset(&sigcatch);
cutime = cstime = utime = stime = cputime_zero;
+
+ mutex_lock(&tty_mutex);
read_lock(&tasklist_lock);
if (task->sighand) {
spin_lock_irq(&task->sighand->siglock);
@@ -388,6 +390,7 @@
}
ppid = pid_alive(task) ? task->group_leader->real_parent->tgid : 0;
read_unlock(&tasklist_lock);
+ mutex_unlock(&tty_mutex);
if (!whole || num_threads<2)
wchan = get_wchan(task);
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2006-08-16 16:12 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-08-16 16:33 PATCH: Stop the tty vanishing under procfs access Alan Cox
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome