aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/linux-2.6/xfs_vnode.h
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/linux-2.6/xfs_vnode.h')
-rw-r--r--fs/xfs/linux-2.6/xfs_vnode.h28
1 files changed, 12 insertions, 16 deletions
diff --git a/fs/xfs/linux-2.6/xfs_vnode.h b/fs/xfs/linux-2.6/xfs_vnode.h
index cc53687ff826..0d7eac03bdf0 100644
--- a/fs/xfs/linux-2.6/xfs_vnode.h
+++ b/fs/xfs/linux-2.6/xfs_vnode.h
@@ -69,22 +69,18 @@ static inline int vn_count(bhv_vnode_t *vp)
69 return atomic_read(&vp->i_count); 69 return atomic_read(&vp->i_count);
70} 70}
71 71
72/* 72#define IHOLD(ip) \
73 * Vnode reference counting functions (and macros for compatibility). 73do { \
74 */ 74 ASSERT(atomic_read(&VFS_I(ip)->i_count) > 0) ; \
75extern bhv_vnode_t *vn_hold(bhv_vnode_t *); 75 atomic_inc(&(VFS_I(ip)->i_count)); \
76 76 xfs_itrace_hold((ip), __FILE__, __LINE__, (inst_t *)__return_address); \
77#if defined(XFS_INODE_TRACE) 77} while (0)
78#define VN_HOLD(vp) \ 78
79 ((void)vn_hold(vp), \ 79#define IRELE(ip) \
80 xfs_itrace_hold(XFS_I(vp), __FILE__, __LINE__, (inst_t *)__return_address)) 80do { \
81#define VN_RELE(vp) \ 81 xfs_itrace_rele((ip), __FILE__, __LINE__, (inst_t *)__return_address); \
82 (xfs_itrace_rele(XFS_I(vp), __FILE__, __LINE__, (inst_t *)__return_address), \ 82 iput(VFS_I(ip)); \
83 iput(vp)) 83} while (0)
84#else
85#define VN_HOLD(vp) ((void)vn_hold(vp))
86#define VN_RELE(vp) (iput(vp))
87#endif
88 84
89static inline bhv_vnode_t *vn_grab(bhv_vnode_t *vp) 85static inline bhv_vnode_t *vn_grab(bhv_vnode_t *vp)
90{ 86{