fuse: use iomap for buffered reads + readahead
Status from this message: Applied to the vfs-6.19.iomap branch of the vfs/vfs.git tree.
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v5 Latest14 patches 13 repliesApplied
- v415 patches 7 repliesSuperseded
- v315 patches 22 repliesSuperseded
Earlier versions · 2
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v2 | 16 patches | 43 replies | Superseded | |
| v1 | 16 patches | 47 replies | Superseded |
Changes in v5 from the cover letter
* Add commit for tracking pending read bytes more optimally (patch 7), which was suggested by Darrick and improves both the performance and the interface
* Merged "track read/readahead folio ownership internally" patch into patch 7
* Split iomap iter pos change into its own commit (Darrick) (patch 8)
Patches in v5 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/14 | iomap: move bio read logic into helper functionfs/ | +39 | 0 replies | |
| 2/14 | iomap: move read/readahead bio submission logic into helper functionfs/ | +16 | 0 replies | |
| 3/14 | iomap: store read/readahead bio genericallyfs/ | +14 | 0 replies | |
| 4/14 | iomap: iterate over folio mapping in iomap_readpage_iter()fs/ | +25 | 0 replies | |
| 5/14 | iomap: rename iomap_readpage_iter() to iomap_read_folio_iter()fs/ | +3 | 0 replies | |
| 6/14 | iomap: rename iomap_readpage_ctx struct to iomap_read_folio_ctxfs/ | +7 | 0 replies | |
| 7/14 | iomap: track pending read bytes more optimallyfs/ | +66 | 12 replies | |
| 8/14 | iomap: set accurate iter->pos when reading folio rangesfs/ | +13 | 0 replies | |
| 9/14 | iomap: add caller-provided callbacks for read and readaheadDocumentation/ block/ fs/ +5 more | +149 | 0 replies | |
| 10/14 | iomap: move buffered io bio logic into new filefs/ fs/ fs/ +1 more | +103 | 0 replies | |
| 11/14 | iomap: make iomap_read_folio() a void returnfs/ include/ | +2 | 0 replies | |
| 12/14 | fuse: use iomap for read_foliofs/ | +56 | 22 replies | |
| 13/14 | fuse: use iomap for readaheadfs/ | +124 | 0 replies | |
| 14/14 | fuse: remove fc->blkbits workaround for partial writesfs/ fs/ fs/ | +2 | 0 replies |
Reviews trailers per patch
11 of 14 patches have a Reviewed-by or Acked-by.
| Patch | Darrick J. Wong | Christoph Hellwig |
|---|---|---|
| 1/14 | R-b | |
| 2/14 | R-b | |
| 3/14 | R-b | |
| 4/14 | R-b | R-b |
| 5/14 | R-b | R-b |
| 6/14 | R-b | R-b |
| 7/14 | ||
| 8/14 | ||
| 9/14 | ||
| 10/14 | R-b | |
| 11/14 | R-b | |
| 12/14 | R-b | |
| 13/14 | R-b | |
| 14/14 | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v5 00/14] fuse: use iomap for buffered reads + readahead
This series adds fuse iomap support for buffered reads and readahead. This is needed so that granular uptodate tracking can be used in fuse when large folios are enabled so that only the non-uptodate portions of the folio need to be read in instead of having to read in the entire folio. It also is needed in order to turn on large folios for servers that use the writeback cache since otherwise there is a race condition that may lead to data corruption if there is a partial write, then a read and the read happens before the write has undergone writeback, since otherwise the folio will not be marked uptodate from the partial write so the read will read in the entire folio from disk, which will overwrite the partial write.
This is on top of two locally-patched iomap patches [1] [2] patched on top of commit f1c864be6e88 ("Merge branch 'vfs-6.18.async' into vfs.all") in Christian's vfs.all tree.
This series was run through fstests on fuse passthrough_hp with an out-of kernel patch enabling fuse large folios.
This patchset does not enable large folios on fuse yet. That will be part of a different patchset.
Thanks,
Joanne
[1] https://lore.kernel.org/linux-fsdevel/[email protected]/
[2] https://lore.kernel.org/linux-fsdevel/[email protected]/
Changelog
---------
v4:
https://lore.kernel.org/linux-fsdevel/[email protected]/
v4 -> v5:
* Add commit for tracking pending read bytes more optimally (patch 7), which was suggested by Darrick and improves both the performance and the interface
* Merged "track read/readahead folio ownership internally" patch into patch 7
* Split iomap iter pos change into its own commit (Darrick) (patch 8)
v3:
https://lore.kernel.org/linux-fsdevel/[email protected]/
v3 -> v4:
* Rebase this on top of patches [1] and [2]
* Fix readahead logic back to checking offset == 0 (patch 4)
* Bias needs to be before/after iomap_iter() (patch 10)
* Rename cur_folio_owned to folio_owned for read_folio (patch 7) (Darrick)
v2:
https://lore.kernel.org/linux-fsdevel/[email protected]/
v2 -> v3:
* Incorporate Christoph's feedback
- Change naming to iomap_bio_* instead of iomap_xxx_bio
- Take his patch for moving bio logic into its own file (patch 11)
- Make ->read_folio_range interface not need pos arg (patch 9)
- Make ->submit_read return void (patch 9)
- Merge cur_folio_in_bio rename w/ tracking folio_owned internally (patch 7)
- Drop patch propagating error and replace with void return (patch 12)
- Make bias code better to read (patch 10)
* Add WARN_ON_ONCE check in iteration refactoring (patch 4)
* Rename ->read_submit to ->submit_read (patch 9)
v1:
https://lore.kernel.org/linux-fsdevel/[email protected]/
v1 -> v2:
* Don't pass in caller-provided arg through iter->private, pass it through ctx->private instead (Darrick & Christoph)
* Separate 'bias' for ifs->read_bytes_pending into separate patch (Christoph)
* Rework read/readahead interface to take in struct iomap_read_folio_ctx (Christoph)
* Add patch for removing fuse fc->blkbits workaround, now that Miklos's tree has been merged into Christian's
Joanne Koong (14):
iomap: move bio read logic into helper function
iomap: move read/readahead bio submission logic into helper function
iomap: store read/readahead bio generically
iomap: iterate over folio mapping in iomap_readpage_iter()
iomap: rename iomap_readpage_iter() to iomap_read_folio_iter()
iomap: rename iomap_readpage_ctx struct to iomap_read_folio_ctx
iomap: track pending read bytes more optimally
iomap: set accurate iter->pos when reading folio ranges
iomap: add caller-provided callbacks for read and readahead
iomap: move buffered io bio logic into new file
iomap: make iomap_read_folio() a void return
fuse: use iomap for read_folio
fuse: use iomap for readahead
fuse: remove fc->blkbits workaround for partial writes
.../filesystems/iomap/operations.rst | 44 +++ block/fops.c | 5 +- fs/erofs/data.c | 5 +- fs/fuse/dir.c | 2 +- fs/fuse/file.c | 288 +++++++++++------- fs/fuse/fuse_i.h | 8 - fs/fuse/inode.c | 13 +- fs/gfs2/aops.c | 6 +- fs/iomap/Makefile | 3 +- fs/iomap/bio.c | 88 ++++++ fs/iomap/buffered-io.c | 246 +++++++-------- fs/iomap/internal.h | 12 + fs/xfs/xfs_aops.c | 5 +- fs/zonefs/file.c | 5 +- include/linux/iomap.h | 63 +++- 15 files changed, 505 insertions(+), 288 deletions(-) create mode 100644 fs/iomap/bio.c
Signature · 1 line
2.47.3