Skip to content

Commit 707c5d3

Browse files
joannekoongbrauner
authored andcommitted
fuse: hook into iomap for invalidating and checking partial uptodateness
Hook into iomap_invalidate_folio() so that if the entire folio is being invalidated during truncation, the dirty state is cleared and the folio doesn't get written back. As well the folio's corresponding ifs struct will get freed. Hook into iomap_is_partially_uptodate() since iomap tracks uptodateness granularly when it does buffered writes. Signed-off-by: Joanne Koong <joannelkoong@gmail.com> Link: https://lore.kernel.org/20250715202122.2282532-5-joannelkoong@gmail.com Reviewed-by: Darrick J. Wong <djwong@kernel.org> Signed-off-by: Christian Brauner <brauner@kernel.org>
1 parent 1097a87 commit 707c5d3

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

fs/fuse/file.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3110,6 +3110,8 @@ static const struct address_space_operations fuse_file_aops = {
31103110
.launder_folio = fuse_launder_folio,
31113111
.dirty_folio = iomap_dirty_folio,
31123112
.release_folio = iomap_release_folio,
3113+
.invalidate_folio = iomap_invalidate_folio,
3114+
.is_partially_uptodate = iomap_is_partially_uptodate,
31133115
.migrate_folio = filemap_migrate_folio,
31143116
.bmap = fuse_bmap,
31153117
.direct_IO = fuse_direct_IO,

0 commit comments

Comments
 (0)