copy: with fiemap copy, only sync when needed
commitf69876e558782eb770955aa0b1344a5a8262548b
authorPádraig Brady <P@draigBrady.com>
Wed, 30 Mar 2011 21:50:05 +0000 (30 22:50 +0100)
committerPádraig Brady <P@draigBrady.com>
Thu, 31 Mar 2011 15:46:42 +0000 (31 16:46 +0100)
tree57d7c29f644b72239a92e0108408955ae29de39f
parent17a7e4592727b44d0a5550d1340e354786109af7
copy: with fiemap copy, only sync when needed

* src/extent-scan.h (struct extent_scan): Add the fm_flags member to
pass to the fiemap scan.
* src/extent-scan.c (extent_need_sync): A new function used to
detect Linux kernels before 2.6.38.
(extent_scan_init): Add FIEMAP_FLAG_SYNC when needed.
* tests/cp/sparse-fiemap: Adjust comment.
* NEWS: Mention the change in behavior.
Indirectly suggested by Mike Frysinger
NEWS
src/extent-scan.c
src/extent-scan.h
tests/cp/sparse-fiemap