xfs: global error sign conversion
[deliverable/linux.git] / fs / xfs / xfs_trans.c
index d03932564ccb3a3e75efc3e39b3991ba6f27d8c9..30e8e34109553d3aee7673382f8b2ab2e44c8446 100644 (file)
@@ -190,7 +190,7 @@ xfs_trans_reserve(
                                          -((int64_t)blocks), rsvd);
                if (error != 0) {
                        current_restore_flags_nested(&tp->t_pflags, PF_FSTRANS);
-                       return (XFS_ERROR(ENOSPC));
+                       return -ENOSPC;
                }
                tp->t_blk_res += blocks;
        }
@@ -241,7 +241,7 @@ xfs_trans_reserve(
                error = xfs_mod_incore_sb(tp->t_mountp, XFS_SBS_FREXTENTS,
                                          -((int64_t)rtextents), rsvd);
                if (error) {
-                       error = XFS_ERROR(ENOSPC);
+                       error = -ENOSPC;
                        goto undo_log;
                }
                tp->t_rtx_res += rtextents;
@@ -874,7 +874,7 @@ xfs_trans_commit(
                goto out_unreserve;
 
        if (XFS_FORCED_SHUTDOWN(mp)) {
-               error = XFS_ERROR(EIO);
+               error = -EIO;
                goto out_unreserve;
        }
 
@@ -917,7 +917,7 @@ out_unreserve:
        if (tp->t_ticket) {
                commit_lsn = xfs_log_done(mp, tp->t_ticket, NULL, log_flags);
                if (commit_lsn == -1 && !error)
-                       error = XFS_ERROR(EIO);
+                       error = -EIO;
        }
        current_restore_flags_nested(&tp->t_pflags, PF_FSTRANS);
        xfs_trans_free_items(tp, NULLCOMMITLSN, error ? XFS_TRANS_ABORT : 0);
@@ -1024,7 +1024,7 @@ xfs_trans_roll(
         */
        error = xfs_trans_commit(trans, 0);
        if (error)
-               return (error);
+               return error;
 
        trans = *tpp;
 
This page took 0.029928 seconds and 5 git commands to generate.