xfs: global error sign conversion
[deliverable/linux.git] / fs / xfs / xfs_trans.c
index 54a57326d85b1e7b2fc84b5761773453a6c02eaf..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;
@@ -827,7 +827,7 @@ xfs_trans_committed_bulk(
                xfs_log_item_batch_insert(ailp, &cur, log_items, i, commit_lsn);
 
        spin_lock(&ailp->xa_lock);
-       xfs_trans_ail_cursor_done(ailp, &cur);
+       xfs_trans_ail_cursor_done(&cur);
        spin_unlock(&ailp->xa_lock);
 }
 
@@ -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.172042 seconds and 5 git commands to generate.