[Linux-ia64] Re: deadlock in crashed multithreaded job

From: Manfred Spraul <manfred_at_colorfullife.com>
Date: 2001-10-03 01:46:41
Erich Focht wrote:
> The question that remains is how to deal with nested locks on the same
> resource that can lead to deadlocks. Is there any (un)written rule that
> one should avoid them in the Linux Kernel? Or are there any approaches to
> deal with them (which are not yet included in the Kernel)?

Yes, semaphores and spinlocks are not recursive. There is one exception
for rw spinlocks, they can recurse on read. I'm not aware that there are
any plans to change that.

My patch avoids calling copy_from_user in elf_core_dump, Andrea adds a 
limited recursion support and uses that to prevent the deadlock.
With his patch you can recurse on on down_read() if you pass special

But full recursion support is not planned.

Received on Tue Oct 02 08:47:06 2001

This archive was generated by hypermail 2.1.8 : 2005-08-02 09:20:05 EST