thread_lock vs panic/trap
John Baldwin
jhb at freebsd.org
Fri May 6 20:19:43 UTC 2011
On Friday, May 06, 2011 5:11:57 am Andriy Gapon wrote:
>
> Can a current thread panic or receive a trap while some other thread holds its
> thread_lock (the same lock as pointed to by the td_lock)?
I'm sure it's theoretically possible. If the thread is running just about
anywhere and another thread is changing its cpuset for example, then you could
run into this.
> And a related question, can there be a reason for a thread in panic or kdb
> context to try to get the thread_lock?
I think it isn't safe to try to grab one's own thread lock in panic or kdb
for this reason.
--
John Baldwin
More information about the freebsd-hackers
mailing list