kern/59945: nullfs bug: reboot after panic: null_checkvp [4.9]

Brian Buchanan bwb at holo.org
Mon Aug 2 20:30:32 PDT 2004


The following reply was made to PR kern/59945; it has been noted by GNATS.

From: Brian Buchanan <bwb at holo.org>
To: freebsd-gnats-submit at freebsd.org
Cc:  
Subject: Re: kern/59945: nullfs bug: reboot after panic: null_checkvp [4.9]
Date: Mon, 2 Aug 2004 20:21:22 -0700 (PDT)

 This is almost certainly still an issue in 4.10, however, it will not
 occur unless DIAGNOSTIC is defined.
 
 getnewvnode() attempts a VOP_GETVOBJECT() on a nullfs vnode.
 null_getvobject() uses the NULLVPTOLOWERVP() macro to get the lower vnode
 so that its vm_object can be returned.  However, for a free nullfs vnode,
 there is no lower vnode.  null_checkvp() will be invoked as a result of
 the macro, and it will panic when it finds that lowervp is not set.
 
 #ifdef DIAGNOSTIC
 struct vnode *null_checkvp(struct vnode *vp, char *fil, int lno);
 #define NULLVPTOLOWERVP(vp) null_checkvp((vp), __FILE__, __LINE__)
 #else
 #define NULLVPTOLOWERVP(vp) (VTONULL(vp)->null_lowervp)
 #endif
 
 null_getvobject() needs to test whether the vnode is still alive before it
 tries to descend into its data structures.  Or, alternately, the patch tjr
 was working on will fix this by delaying the cleanup of the null vode and
 its associated data structures until the reclaim operation.
 
 


More information about the freebsd-bugs mailing list