Commit 9936b07d authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] fix deadlock over proc_lock

From: Manfred Spraul <manfred@colorfullife.com>

Martin found out what caused the deadlocks with 2.5.70 and SDET: I forgot
to initialize proc_lock during fork().  Usually this works, because the
parent lock is unlocked.  But a proc lookup during fork can cause it to be
locked, and then the system locks up.
parent 40d45b93
......@@ -846,6 +846,7 @@ struct task_struct *copy_process(unsigned long clone_flags,
p->vfork_done = NULL;
spin_lock_init(&p->alloc_lock);
spin_lock_init(&p->switch_lock);
spin_lock_init(&p->proc_lock);
clear_tsk_thread_flag(p, TIF_SIGPENDING);
init_sigpending(&p->pending);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment