Subject: Re: frequent panics in sysctl_doeproc
To: Tobias Nygren <tnn@NetBSD.org>
From: Andrew Doran <firstname.lastname@example.org>
Date: 07/30/2007 23:31:15
On Mon, Jul 30, 2007 at 07:03:33PM +0200, Tobias Nygren wrote:
> I could really use some help analysing this crash.
> My sparc64 box has been panicing alot recently when running top(1).
> The backtrace is rather odd. My current theory is that we assume
> that some page is wired when it actually isn't. Is the any other
> possible reason for taking a fault when attempting to lock a mutex?
sysctl relies on the target buffer to be wired and IIRC calls uvm_vslock()
to do that. uvm_vslock() is broken in a number of ways. Really we need to
look at modifying all of the sysctl grovellers to not assume that the memory
is locked (and so not take liberties like holding locks across copyout()).
I've made a start on that in places but there is still a lot to do.