On Mon, Jan 12, 2009 at 05:19:56PM +0100, Alexej Sokolov wrote:
> 2009/1/12 Mateusz Guzik <mjgu...@gmail.com>
> > Mutexes have owners. It panics on loading because processes cannot
> > return to userland with locks held.
> 
> i am not sure about it. Some time ago i implemented a charecter device with
> two syscalls: write, read. "write" lock the mutex and  "read" unlock it. The
> user space programm opens device, then mekes "write" (mutex will held in
> kernel), goes back to user space, then makes "read" (mutex will unlocked in
> kernel) and it all run without panic. If needed i can post the source code.
> 

Do you have kernel compiled with WITNESS? At least on -CURRENT the
kernel panicked like this (while loading your module):

System call kldload returning with 1 locks held

-- 
Mateusz Guzik <mjguzik at gmail.com>
_______________________________________________
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"

Reply via email to