vfs: inline vrefcnt
This commit is contained in:
parent
4c2d103a02
commit
36f47512d9
@ -2952,22 +2952,6 @@ vrefact(struct vnode *vp)
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
* Return reference count of a vnode.
|
||||
*
|
||||
* The results of this call are only guaranteed when some mechanism is used to
|
||||
* stop other processes from gaining references to the vnode. This may be the
|
||||
* case if the caller holds the only reference. This is also useful when stale
|
||||
* data is acceptable as race conditions may be accounted for by some other
|
||||
* means.
|
||||
*/
|
||||
int
|
||||
vrefcnt(struct vnode *vp)
|
||||
{
|
||||
|
||||
return (vp->v_usecount);
|
||||
}
|
||||
|
||||
void
|
||||
vlazy(struct vnode *vp)
|
||||
{
|
||||
|
@ -967,8 +967,13 @@ void vrele(struct vnode *vp);
|
||||
void vref(struct vnode *vp);
|
||||
void vrefl(struct vnode *vp);
|
||||
void vrefact(struct vnode *vp);
|
||||
int vrefcnt(struct vnode *vp);
|
||||
void v_addpollinfo(struct vnode *vp);
|
||||
static __inline int
|
||||
vrefcnt(struct vnode *vp)
|
||||
{
|
||||
|
||||
return (vp->v_usecount);
|
||||
}
|
||||
|
||||
int vnode_create_vobject(struct vnode *vp, off_t size, struct thread *td);
|
||||
void vnode_destroy_vobject(struct vnode *vp);
|
||||
|
Loading…
x
Reference in New Issue
Block a user