Subject: Re: procfs locking troubles
To: None <skrueger@europe.com>
From: Jaromir Dolecek <jdolecek@NetBSD.org>
List: current-users
Date: 02/15/2004 11:01:17
skrueger@europe.com wrote:
> hi folks, I've seen the following on my console (I need to write it down
> cause syslog didn't log it):
> 
> Simple_lock: locking against myself
> lock: 0xcb625b74, currently at: /usr/src/sys/kern/kern_descrip.c:202 on cpu 0
> last locked: /usr/src/sys/kern/kern_descrip.c:202
> last unlocked: /usr/src/sys/kern/sys_generic.c:97

In these cases, the very first such messages indicate the problem
place best. Can you re-try that and post the first 2-3 messages?

It's wierd it didn't get logged via syslog - do you have
kern facility configured to be logged in /etc/syslog.conf ?

Jaromir

> (repeated several times)
> 
> pool_cache_get(PR_WAITOK) with held simple_lock 0xcb625b74 CPU 0 /usr/src/sys/kern/kern_descrip.c:202
> 
> simple_lock: locking against myself
> (same as above, repeated several times again)
> 
> $ gdb /netbsd
> [...]
> (gdb) x 0xcb625b74:     Cannot access memory at address 0xcb625b74
> 
> hhhmmmmm strange...
> 
> $ ident /netbsd
> $NetBSD: kern_descrip.c,v 1.123 2004/01/07 09:26:29 jdolecek Exp $
> $NetBSD: sys_generic.c,v 1.80 2003/10/10 15:24:28 chs Exp $
> $NetBSD: procfs_vnops.c,v 1.110 2003/10/30 01:58:18 simonb Exp $
> 
> $ uname -a
> NetBSD localhost 1.6ZJ NetBSD 1.6ZJ (KOERNEL.MP) #1: Tue Feb 10 16:43:18 CET 2004  skrueger@localhost:/usr/src/sys/arch/i386/compile/KOERNEL.MP i386
> 
> I've also seen:
> 
> simple_lock: locking against myself
> lock: 0xcb625d04, currently at: /usr/src/sys/kern/kern_descript.c:202 on cpu 0
> last locked: /usr/src/sys/kern/kern_descript.c:202
> last unlocked: /usr/src/sys/miscfs/procfs/procfs_vnops.c:954
> 
> and some other msgs, but I wasn't able to catch them :-(
> 
> how to reproduce:
> 
> compile your kernel with LOCKDEBUG and DIAGNOSTIC, (and MPDEBUG in my case)
> # mount -t procfs -o linux procfs /proc # don't know if linux is related, but again my case
> $ tar cf - /proc > /dev/null
> 
> running this several times locked my machine up, screen freezed, no keyboard...
> 
> hope this helps,
> SK
> 
> -- 
> ___________________________________________________________
> Sign-up for Ads Free at Mail.com
> http://promo.mail.com/adsfreejump.htm
> 

-- 
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.''   -=-