aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_iget.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/xfs_iget.c')
-rw-r--r--fs/xfs/xfs_iget.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/fs/xfs/xfs_iget.c b/fs/xfs/xfs_iget.c
index cdb1c2505fc..9fae4755660 100644
--- a/fs/xfs/xfs_iget.c
+++ b/fs/xfs/xfs_iget.c
@@ -105,6 +105,18 @@ xfs_inode_alloc(
105} 105}
106 106
107void 107void
108__xfs_inode_free(
109 struct rcu_head *head)
110{
111 struct inode *inode = container_of((void *)head,
112 struct inode, i_dentry);
113 struct xfs_inode *ip = XFS_I(inode);
114
115 INIT_LIST_HEAD(&inode->i_dentry);
116 kmem_zone_free(xfs_inode_zone, ip);
117}
118
119void
108xfs_inode_free( 120xfs_inode_free(
109 struct xfs_inode *ip) 121 struct xfs_inode *ip)
110{ 122{
@@ -147,7 +159,7 @@ xfs_inode_free(
147 ASSERT(!spin_is_locked(&ip->i_flags_lock)); 159 ASSERT(!spin_is_locked(&ip->i_flags_lock));
148 ASSERT(completion_done(&ip->i_flush)); 160 ASSERT(completion_done(&ip->i_flush));
149 161
150 kmem_zone_free(xfs_inode_zone, ip); 162 call_rcu((struct rcu_head *)&VFS_I(ip)->i_dentry, __xfs_inode_free);
151} 163}
152 164
153/* 165/*