Subject: kern/3915: panic on reboot
To: None <gnats-bugs@gnats.netbsd.org>
From: Patrick Welche <prlw1@quantz.newn.cam.ac.uk>
List: netbsd-bugs
Date: 07/24/1997 12:49:15
>Number:         3915
>Category:       kern
>Synopsis:       "locking against myself" on reboot
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people (Kernel Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Jul 24 04:50:00 1997
>Last-Modified:
>Originator:     Patrick Welche
>Organization:
	
>Release:        NetBSD-current/i386 of 23 July 1997
>Environment:
        P133 16Mb RAM
        NetBSD-current/i386 of 23 July 1997
>Description:
panic "locking against myself" after reboot, or halt. In this case the halt
binary was from 23 July sup. The new kernel was about to be rebooted. The
"old" kernel running was about 3 days old.
trace:
_panic(..,..,..,..,93)	+0x46
_lockmgr(..,2,0,..)	+0x2ab
_vm_map_pageable(..,..,..,0)	+0x29
_trap (number 6)	+0x439
_vm_page_insert(a,b,13000,..,..)	+0x91
_vm_page_rename(a,b,13000)	+0x20
_vm_object_overlay(b,b+0x500,..,..,..)	+0xf0
_vm_object_collapse	+0x5b
_vm_object_deallocate	+0x39
_vm_map_entry_delete(c,..,d,0,e)	+0x54
_vm_map_delete(c,0,d,e,..)	+0x104
_vm_map_remove(c,0,d)	+0x62
_exit1(..,0,..,..,..)	+0xd4
_sys_exit	+0x14
_syscall (number 1)
After continue, fails to sync disks.
This is an identical backtrace to the one I posted to current users before
18th July. Frank van der Linden's analysis was:
> A program exits, so its VM resources are removed, vm_map_remove is called,
> which locks the map. During this, somehow a pagefault occurs. The i386 trap
> code needs a page for the page tables (they're recursive), so it calls
> vm_map_pageable. Tha wants to lock the map again, and.. boom.
>How-To-Repeat:
	type "reboot" ! It happened the last 3 times.
>Fix:
	I have no idea!
>Audit-Trail:
>Unformatted: