Skip to content

Commit

Permalink
xfs: remove [cm]time update from reflink calls
Browse files Browse the repository at this point in the history
Now that the vfs remap helper dirties the inode [cm]time for us, xfs no
longer needs to do that on its own.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Signed-off-by: Dave Chinner <david@fromorbit.com>
  • Loading branch information
djwong authored and dchinner committed Oct 29, 2018
1 parent 3fc9f5e commit bf4a1fc
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions fs/xfs/xfs_reflink.c
Original file line number Diff line number Diff line change
Expand Up @@ -927,8 +927,7 @@ xfs_reflink_update_dest(
struct xfs_trans *tp;
int error;

if ((remap_flags & REMAP_FILE_DEDUP) &&
newlen <= i_size_read(VFS_I(dest)) && cowextsize == 0)
if (newlen <= i_size_read(VFS_I(dest)) && cowextsize == 0)
return 0;

error = xfs_trans_alloc(mp, &M_RES(mp)->tr_ichange, 0, 0, 0, &tp);
Expand All @@ -949,10 +948,6 @@ xfs_reflink_update_dest(
dest->i_d.di_flags2 |= XFS_DIFLAG2_COWEXTSIZE;
}

if (!(remap_flags & REMAP_FILE_DEDUP)) {
xfs_trans_ichgtime(tp, dest,
XFS_ICHGTIME_MOD | XFS_ICHGTIME_CHG);
}
xfs_trans_log_inode(tp, dest, XFS_ILOG_CORE);

error = xfs_trans_commit(tp);
Expand Down

0 comments on commit bf4a1fc

Please sign in to comment.