Christoph Hellwig 45dd052e67 fs: handle FIEMAP_FLAG_SYNC in fiemap_prep
By moving FIEMAP_FLAG_SYNC handling to fiemap_prep we ensure it is
handled once instead of duplicated, but can still be done under fs locks,
like xfs/iomap intended with its duplicate handling.  Also make sure the
error value of filemap_write_and_wait is propagated to user space.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Amir Goldstein <amir73il@gmail.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Link: https://lore.kernel.org/r/20200523073016.2944131-8-hch@lst.de
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
2020-06-03 23:16:55 -04:00
..
2019-11-30 14:12:13 -08:00
2019-09-24 15:54:07 -07:00
2020-04-02 09:35:25 -07:00
2020-04-02 09:35:25 -07:00
2018-12-28 12:11:45 -08:00
2019-09-24 15:54:07 -07:00
2020-04-02 09:35:25 -07:00
2020-04-02 09:35:25 -07:00