On Wed, Feb 18, 2004 at 11:52:26AM -0800, Jerry Toung wrote: > Hello hackers, > I am constantly getting the following message when I run my KLD: > > panic: lockmgr: locking against myself > Debugger("panic") > Stopped at Debugger+0x54: xchgl %ebx,in_Debugger.0 > db> > > What could possibly cause this? > It seem to say that I'm locking an already locked variable. >
Hello Jerry, According to kern/kern_lock.c:lockmgr() your proc/thread already has an exclusive lock and it tries to obtain a recursive exclusive lock and lock doesn't have LK_CANRECURSE flag (also you allow to sleep in lockmng()). This is documented in lock(9) manual page: LK_EXCLUSIVE Acquire an exclusive lock. If an exclusive lock is already held, and LK_CANRECURSE is not set, the system will panic(9). _______________________________________________ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"