DragonFly On-Line Manual Pages
VHOLD(9) DragonFly Kernel Developer's Manual VHOLD(9)
vhold, vdrop -- Acquire/release an auxiliary reference on a vnode
vhold(struct vnode *vp);
vdrop(struct vnode *vp);
The vhold() function acquires an auxiliary reference on a vnode by incre-
menting the v_auxrefs field. Auxiliary references do not reactivate a
vnode or move it to the cache if it resides on the free list, but they
will prevent the vnode from being recycled (if not already being recy-
cled), or reused. Auxiliary references are used to associate auxiliary
structures such as namecache records with the vnode for those cases where
the intent is to not allow the vnode to be immediately recycled. Auxil-
iary references are also used to access a vnode via an auxiliary struc-
ture without having to hold a deep stack of locks that might create dead-
lock issues for the caller.
The vdrop() function decrements the v_auxrefs field. If the vnode has
been deactivated and resides in the cache, it will be moved to the free
list when v_auxrefs drops to 0.
vget(9), vnode(9), vn_lock(9), vn_unlock(9), vput(9), vref(9), vrele(9)
This manual page was written by Chad David <firstname.lastname@example.org>.
DragonFly 5.3 May 5, 2007 DragonFly 5.3