]> err.no Git - linux-2.6/commitdiff
[XFS] Remove unnecessary local from open_exec dmapi path.
authorNathan Scott <nathans@sgi.com>
Sun, 18 Jun 2006 22:39:16 +0000 (08:39 +1000)
committerNathan Scott <nathans@sgi.com>
Sun, 18 Jun 2006 22:39:16 +0000 (08:39 +1000)
SGI-PV: 904196
SGI-Modid: xfs-linux-melb:xfs-kern:26247a

Signed-off-by: Nathan Scott <nathans@sgi.com>
fs/xfs/linux-2.6/xfs_file.c

index 89b1a74213573306a6a8eb9da9aa0045f6333c82..cf65a8364d5aea8704fade55b95beed3646cdbcc 100644 (file)
@@ -522,23 +522,18 @@ xfs_file_open_exec(
        struct inode    *inode)
 {
        bhv_vnode_t     *vp = vn_from_inode(inode);
-       xfs_mount_t     *mp = XFS_VFSTOM(vp->v_vfsp);
-       int             error = 0;
-       xfs_inode_t     *ip;
 
-       if (vp->v_vfsp->vfs_flag & VFS_DMI) {
-               ip = xfs_vtoi(vp);
-               if (!ip) {
-                       error = -EINVAL;
-                       goto open_exec_out;
-               }
-               if (DM_EVENT_ENABLED(vp->v_vfsp, ip, DM_EVENT_READ)) {
-                       error = -XFS_SEND_DATA(mp, DM_EVENT_READ, vp,
+       if (unlikely(vp->v_vfsp->vfs_flag & VFS_DMI)) {
+               xfs_mount_t     *mp = XFS_VFSTOM(vp->v_vfsp);
+               xfs_inode_t     *ip = xfs_vtoi(vp);
+
+               if (!ip)
+                       return -EINVAL;
+               if (DM_EVENT_ENABLED(vp->v_vfsp, ip, DM_EVENT_READ))
+                       return -XFS_SEND_DATA(mp, DM_EVENT_READ, vp,
                                               0, 0, 0, NULL);
-               }
        }
-open_exec_out:
-       return error;
+       return 0;
 }
 #endif /* HAVE_FOP_OPEN_EXEC */