Re: panic: proc not held _at_ fs/procfs/procfs_regs.c:60

From: John Baldwin <jhb_at_FreeBSD.org>
Date: Thu, 13 Jan 2005 13:43:26 -0500
On Thursday 13 January 2005 06:49 am, Peter Holm wrote:
> On Wed, Jan 12, 2005 at 03:03:29PM -0500, John Baldwin wrote:
> > On Sunday 09 January 2005 04:44 pm, Peter Holm wrote:
> > > With GENERIC HEAD from Jan 8 08:45 UTC I got:
> > >
> > > panic(c0826351,c0826973,c082fcfc,3,c175a2e0) at panic+0xd8
> > > procfs_doprocregs(c175a2e0,c1b1b5e8,c1665d80,0,ce778c90) at
> > > procfs_doprocregs+0x10a pfs_read(ce778c1c,20000,c1f19e04,c08294ba,845)
> > > at pfs_read+0x20f
> > > vn_read(c1b17ae4,ce778c90,c1a9c080,0,c175a2e0) at vn_read+0x1b9
> > > dofileread(8,bfbfea50,4c,ffffffff,ffffffff) at dofileread+0x82
> > > read(c175a2e0,ce778d14,3,1,282) at read+0x44
> > > syscall(2f,2f,2f,8059f48,a7c) at syscall+0x128
> > >
> > > Details at http://www.holm.cc/stress/log/cons105.html
> >
> > Hmm, looking at procfs_doprocregs() I'm not sure how it could lose the
> > proc lock.  The assertion must be in one of the PROC_UNLOCK().  Can you
> > do a listing of the procfs_doprocregs() frame to see where it died?
>
> No, sorry. I seem to have fumbled the backup of the tree before I
> did an update :-(
>
> But isn't the panic in this code:
>
> procfs_regs.c, Revision 1.29.2.1
> 1.24      jhb        59:        PROC_LOCK(p);
> 1.29.2.1! das        60:        KASSERT(p->p_lock > 0, ("proc not held"));

Ah, doh.  Too many different locks around. :(  Weird, pfs_read() does a _PHOLD 
and PRELE around calling procfs_doprocregs(), so I'm not sure how this 
happened.

-- 
John Baldwin <jhb_at_FreeBSD.org>  <><  http://www.FreeBSD.org/~jhb/
"Power Users Use the Power to Serve"  =  http://www.FreeBSD.org
Received on Thu Jan 13 2005 - 17:52:34 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:26 UTC