Re: [PATCH 12/41] fs: Drop sync_mapping_buffers() from __generic_file_fsync()

Jan Kara
2026-03-25T19:01:52Z

On Tue 24-03-26 08:54:22, Christoph Hellwig wrote:
> On Tue, Mar 24, 2026 at 02:36:53PM +0100, Jan Kara wrote:
> > Leaving the two implementations separate certainly works for me as well
> > (that's why I've put that patch to the end because I've expected some
> > discussions around it :)). Just the amount of common trivial calls you need
> > to do (fdatawrite(), sync_inode_metadata(),
> > file_check_and_advance_wb_err(), blkdev_issue_flush()) looked high enough
> > to me to be worth merging the implementations. But I don't feel strongly
> > either way.
>
> I don't really feel either way, and I really should not micro-manage
> the series either. So go for what you think works best. The important
> part is to have the fsync changes early and to avoid hardcoding
> buffer_head knowledge into libfs.c.

After trying with the callback and not liking it too much in the end I've
just decided to stay with two separate implementations.

Honza
--
Jan Kara <jack@suse.com>
SUSE Labs, CR