Current-Users archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: "locking against myself" with sysmon_envsys/libprop stuff



On Tue, 6 May 2008 12:15:21 +1000
Geoff Wing <gcw%pobox.com@localhost> wrote:

> Here's a current (2008-05-06) problem.
> I believe it was running /etc/rc.d/envsys during boot.
> 
> Regards,
> Geoff
> 
> #0  0xc036fa23 in cpu_reboot (howto=260, bootstr=0x0)
>     at ../../../../arch/i386/i386/machdep.c:891
> #1  0xc016c8a9 in db_reboot_cmd (addr=-1072242227, have_addr=false, 
>     count=-789055728, modif=0xd0f7f680 "\023")
>     at ../../../../ddb/db_command.c:1295
> #2  0xc016c3b1 in db_command (last_cmdp=<value optimized out>)
>     at ../../../../ddb/db_command.c:921
> #3  0xc016c6f4 in db_command_loop () at ../../../../ddb/db_command.c:566
> #4  0xc016f43d in db_trap (type=1, code=0)
> #at ../../../../ddb/db_trap.c:101 5  0xc036b7a3 in kdb_trap (type=1,
> #code=0, regs=0xd0f7f89c)
>     at ../../../../arch/i386/i386/db_interface.c:231
> #6  0xc0373712 in trap (frame=0xd0f7f89c)
>     at ../../../../arch/i386/i386/trap.c:346
> #7  0xc010cedf in calltrap ()
> #8  0xc036a0ac in breakpoint ()
> #9  0xc02e1302 in panic (fmt=0xc050ae7b "LOCKDEBUG")
>     at ../../../../kern/subr_prf.c:257
> #10 0xc02d9dea in lockdebug_abort1 (ld=0xcc077f00, lk=0xc05e39c0, 
>     func=0xc04676de "lockdebug_wantlock", 
>     msg=0xc04f51cb "locking against myself", dopanic=true)
>     at ../../../../kern/subr_lockdebug.c:799
> #11 0xc02bec00 in rw_vector_enter (rw=0xcc08cfc8, op=RW_READER)
>     at ../../../../kern/kern_rwlock.c:297
> #12 0xc0443418 in _prop_dictionary_iterator_reset (v=0xc2af03a0)
>     at 
> ../../../../../../lib/libkern/../../../common/lib/libprop/prop_dictionary.c:602
> #13 0xc0443bf6 in prop_dictionary_iterator (pd=0xcc08cfc0)
>     at 
> ../../../../../../lib/libkern/../../../common/lib/libprop/prop_dictionary.c:767
> #14 0xc0443ca0 in _prop_dictionary_externalize (ctx=0xc2c71070,
> #v=0xcc08cfc0)
>     at 
> ../../../../../../lib/libkern/../../../common/lib/libprop/prop_dictionary.c:412
> #15 0xc0443122 in prop_dictionary_externalize (pd=0xcc08cfc0)
>     at 
> ../../../../../../lib/libkern/../../../common/lib/libprop/prop_dictionary.c:1126
> #16 0xc043fe50 in _prop_object_copyout_ioctl (pref=0xd0f7fc50, 
>     cmd=<value optimized out>, obj=0xcc08cfc0)
>     at 
> ../../../../../../lib/libkern/../../../common/lib/libprop/prop_kern.c:323
> #17 0xc011bebd in sysmonioctl_envsys (dev=17152, cmd=3221767424, 
>     data=0xd0f7fc50, flag=1, l=0xd1037260)
>     at ../../../../dev/sysmon/sysmon_envsys.c:184
> #18 0xc032cabe in spec_ioctl (v=0xd0f7fb40)
>     at ../../../../miscfs/specfs/spec_vnops.c:665
> #19 0xc0325a0d in VOP_IOCTL (vp=0xce46b078, command=3221767424, 
>     data=0xd0f7fc50, fflag=1, cred=0xcc085f00)
>     at ../../../../kern/vnode_if.c:562
> #20 0xc03234bb in vn_ioctl (fp=0xd1087f40, com=3221767424,
> #data=0xd0f7fc50)
>     at ../../../../kern/vfs_vnops.c:624
> #21 0xc02e7ca6 in sys_ioctl (l=0xd1037260, uap=0xd0f7fd00,
> #retval=0xd0f7fd28)
>     at ../../../../kern/sys_generic.c:616
> #22 0xc0373172 in syscall (frame=0xd0f7fd48)
>     at ../../../../arch/i386/i386/syscall.c:102
> #23 0xc010054d in syscall1 ()

The cause is in proplib's code itself and not in sysmon_envsys.

yamt@ added code to detect recursive rwlocks, and it seems
it's catching some of them in proplib.

Not sure what would be the correct fix...

-- 
Juan Romero Pardines - xtraeme at gmail|netbsd dot org
        The NetBSD Project

Make your own NetBSD/x86 Live CD
http://www.netbsd.org/~xtraeme/mklivecd/


Home | Main Index | Thread Index | Old Index