Subject: Re: Final reaper removal patch
To: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
From: Jaromir Dolecek <jdolecek@NetBSD.org>
List: tech-kern
Date: 01/09/2004 10:33:51
YAMAMOTO Takashi wrote:
> lwp_exit2() should acquire kernel lock. otherwise it deadlocks.
I'm not sure. AFAICS it uses correct lock protocol.
Normal lock order is:
1. KERNEL_PROC_LOCK
2. other spinlocks
The lwp_exit2() doesn't take KERNEL_PROC_LOCK(), only takes
the other spinlocks. Thus, it shouldn't deadlock.
Deadlock would be possible only if there would be any code
path where lwp_exit2() acquires some others locks before
taking KERNEL_PROC_LOCK. Right?
Jaromir
--
Jaromir Dolecek <jdolecek@NetBSD.org> http://www.NetBSD.cz/
-=- We should be mindful of the potential goal, but as the Buddhist -=-
-=- masters say, ``You may notice during meditation that you -=-
-=- sometimes levitate or glow. Do not let this distract you.'' -=-