On Tue, May 28, 2024 at 05:48:22PM +0100, Matthew Wilcox (Oracle) wrote: > Start the process of moving write_begin and write_end out from the > address_space_operations to their own struct. > > The new write_begin returns the folio or an ERR_PTR instead of returning > the folio by reference. It also accepts len as a size_t and (as > documented) the len may be larger than PAGE_SIZE. > > Pass an optional buffered_write_operations pointer to various functions > in filemap.c. The old names are available as macros for now, except > for generic_file_write_iter() which is used as a function pointer by > many filesystems. If using the new functions, the filesystem can have > per-operation fsdata instead of per-page fsdata. The model looks good, but buffered_write_operations sounds a little too generic for a helper that hopefully won't have too many users in the end.