diff options
author | Christoph Hellwig <hch@sgi.com> | 2006-01-11 04:58:44 -0500 |
---|---|---|
committer | Nathan Scott <nathans@sgi.com> | 2006-01-11 04:58:44 -0500 |
commit | 75e17b3caf29b262000dc7348f1be9a7d5403463 (patch) | |
tree | 4bdf782dd3624fd23832b035ebbdbb4daca7dd94 /fs/xfs/linux-2.6/xfs_file.c | |
parent | 204ab25f36fbd44a24458c0227cf2629c8caf00d (diff) |
[XFS] add helper to get xfs_inode from vnode
SGI-PV: 947206
SGI-Modid: xfs-linux-melb:xfs-kern:203960a
Signed-off-by: Christoph Hellwig <hch@sgi.com>
Signed-off-by: Nathan Scott <nathans@sgi.com>
Diffstat (limited to 'fs/xfs/linux-2.6/xfs_file.c')
-rw-r--r-- | fs/xfs/linux-2.6/xfs_file.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/fs/xfs/linux-2.6/xfs_file.c b/fs/xfs/linux-2.6/xfs_file.c index 06111d0bbae4..ced4404339c7 100644 --- a/fs/xfs/linux-2.6/xfs_file.c +++ b/fs/xfs/linux-2.6/xfs_file.c | |||
@@ -509,16 +509,14 @@ linvfs_open_exec( | |||
509 | vnode_t *vp = LINVFS_GET_VP(inode); | 509 | vnode_t *vp = LINVFS_GET_VP(inode); |
510 | xfs_mount_t *mp = XFS_VFSTOM(vp->v_vfsp); | 510 | xfs_mount_t *mp = XFS_VFSTOM(vp->v_vfsp); |
511 | int error = 0; | 511 | int error = 0; |
512 | bhv_desc_t *bdp; | ||
513 | xfs_inode_t *ip; | 512 | xfs_inode_t *ip; |
514 | 513 | ||
515 | if (vp->v_vfsp->vfs_flag & VFS_DMI) { | 514 | if (vp->v_vfsp->vfs_flag & VFS_DMI) { |
516 | bdp = vn_bhv_lookup(VN_BHV_HEAD(vp), &xfs_vnodeops); | 515 | ip = xfs_vtoi(vp); |
517 | if (!bdp) { | 516 | if (!ip) { |
518 | error = -EINVAL; | 517 | error = -EINVAL; |
519 | goto open_exec_out; | 518 | goto open_exec_out; |
520 | } | 519 | } |
521 | ip = XFS_BHVTOI(bdp); | ||
522 | if (DM_EVENT_ENABLED(vp->v_vfsp, ip, DM_EVENT_READ)) { | 520 | if (DM_EVENT_ENABLED(vp->v_vfsp, ip, DM_EVENT_READ)) { |
523 | error = -XFS_SEND_DATA(mp, DM_EVENT_READ, vp, | 521 | error = -XFS_SEND_DATA(mp, DM_EVENT_READ, vp, |
524 | 0, 0, 0, NULL); | 522 | 0, 0, 0, NULL); |