Subject: kern/20888: LOCKDEBUG output causes double fault panic
To: None <gnats-bugs@gnats.netbsd.org>
From: Gary Duzan <gary@duzan.org>
List: netbsd-bugs
Date: 03/25/2003 09:55:45
>Number:         20888
>Category:       kern
>Synopsis:       LOCKDEBUG output causes double fault panic
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Mar 25 06:57:00 PST 2003
>Closed-Date:
>Last-Modified:
>Originator:     Gary Duzan
>Release:        NetBSD 1.6Q
>Organization:
	Not a lot
>Environment:
System: NetBSD capo 1.6Q NetBSD 1.6Q (CAPO) #3: Sun Mar 23 09:13:46 EST 2003 gary@capo:/usr/tmp/src/sys/arch/i386/compile/CAPO i386
Architecture: i386
Machine: i386
>Description:
	While copying a bunch of files (using tar, of course) from
	NFS to LFS, I get a double fault panic with the following
	(partial, hand-transcribed) trace:

putchar
kprintf
printf_nolog
lock_printf
_simple_lock
tputchar
putchar
kprintf
printf_nolog
lock_printf
[ ... repeat from _simple_lock about 10 times ... ]
_simple_lock
selwakeup
ptsstart
ttstart
tputchar
putchar
kprintf
printf_nolog
lock_printf
_simple_lock
uvm_swapin
sa_putcachelwp
sa_vp_repossess
sa_upcall_userret
syscall_plain

>How-To-Repeat:
	Unknown
>Fix:
	Presumably, prevent lock_printf from calling anything that
	can attempt to acquire locks, or bail out if called
	recursively. (A static entry/exit counter, perhaps?)
>Release-Note:
>Audit-Trail:
>Unformatted:
 	March 23 18:07 EST