xfs: update ctime and mtime on clone destinatation inodes
authorChristoph Hellwig <hch@lst.de>
Tue, 7 Feb 2017 01:45:51 +0000 (17:45 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 8 Apr 2017 07:30:31 +0000 (09:30 +0200)
commit67eb7bf836af69b967ab437c6c84e81c4351b957
treeceebac53b07151c20c12b16ffb42f9c0e0b6382c
parente060f4884c93eb980c6e2cb3f19bf4b7582fd460
xfs: update ctime and mtime on clone destinatation inodes

commit c5ecb42342852892f978572ddc6dca703460f25a upstream.

We're changing both metadata and data, so we need to update the
timestamps for clone operations.  Dedupe on the other hand does
not change file data, and only changes invisible metadata so the
timestamps should not be updated.

This follows existing btrfs behavior.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
[darrick: remove redundant is_dedupe test]
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/xfs/xfs_reflink.c