aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/linux-2.6
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/linux-2.6')
-rw-r--r--fs/xfs/linux-2.6/xfs_export.c9
-rw-r--r--fs/xfs/linux-2.6/xfs_iops.c6
2 files changed, 7 insertions, 8 deletions
diff --git a/fs/xfs/linux-2.6/xfs_export.c b/fs/xfs/linux-2.6/xfs_export.c
index 21f0e8257590..66a9a9e76cbe 100644
--- a/fs/xfs/linux-2.6/xfs_export.c
+++ b/fs/xfs/linux-2.6/xfs_export.c
@@ -213,17 +213,16 @@ xfs_fs_get_parent(
213 struct dentry *child) 213 struct dentry *child)
214{ 214{
215 int error; 215 int error;
216 bhv_vnode_t *cvp; 216 struct xfs_inode *cip;
217 struct dentry *parent; 217 struct dentry *parent;
218 218
219 cvp = NULL; 219 error = xfs_lookup(XFS_I(child->d_inode), &dotdot, &cip);
220 error = xfs_lookup(XFS_I(child->d_inode), &dotdot, &cvp);
221 if (unlikely(error)) 220 if (unlikely(error))
222 return ERR_PTR(-error); 221 return ERR_PTR(-error);
223 222
224 parent = d_alloc_anon(vn_to_inode(cvp)); 223 parent = d_alloc_anon(cip->i_vnode);
225 if (unlikely(!parent)) { 224 if (unlikely(!parent)) {
226 VN_RELE(cvp); 225 iput(cip->i_vnode);
227 return ERR_PTR(-ENOMEM); 226 return ERR_PTR(-ENOMEM);
228 } 227 }
229 return parent; 228 return parent;
diff --git a/fs/xfs/linux-2.6/xfs_iops.c b/fs/xfs/linux-2.6/xfs_iops.c
index 215158cbac43..01d9b3f1e044 100644
--- a/fs/xfs/linux-2.6/xfs_iops.c
+++ b/fs/xfs/linux-2.6/xfs_iops.c
@@ -372,13 +372,13 @@ xfs_vn_lookup(
372 struct dentry *dentry, 372 struct dentry *dentry,
373 struct nameidata *nd) 373 struct nameidata *nd)
374{ 374{
375 bhv_vnode_t *cvp; 375 struct xfs_inode *cip;
376 int error; 376 int error;
377 377
378 if (dentry->d_name.len >= MAXNAMELEN) 378 if (dentry->d_name.len >= MAXNAMELEN)
379 return ERR_PTR(-ENAMETOOLONG); 379 return ERR_PTR(-ENAMETOOLONG);
380 380
381 error = xfs_lookup(XFS_I(dir), dentry, &cvp); 381 error = xfs_lookup(XFS_I(dir), dentry, &cip);
382 if (unlikely(error)) { 382 if (unlikely(error)) {
383 if (unlikely(error != ENOENT)) 383 if (unlikely(error != ENOENT))
384 return ERR_PTR(-error); 384 return ERR_PTR(-error);
@@ -386,7 +386,7 @@ xfs_vn_lookup(
386 return NULL; 386 return NULL;
387 } 387 }
388 388
389 return d_splice_alias(vn_to_inode(cvp), dentry); 389 return d_splice_alias(cip->i_vnode, dentry);
390} 390}
391 391
392STATIC int 392STATIC int