On 19.09.19 г. 9:14 ч., Omar Sandoval wrote: > On Thu, Sep 05, 2019 at 01:33:56PM +0300, Nikolay Borisov wrote: <snip> >> >> Won't btrfs_lock_and_flush_ordered_range suffice here? Perhaps call that >> function + invalidate_inode_pages2_range ? > > No, btrfs_lock_and_flush_ordered_range() doesn't write out dirty pages, > so it's not sufficient here. But it does - it calls btrfs_start_ordered_extent which calls filemap_fdatawrite_range. > > Thanks for the review! >