summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJoanne Koong <joannelkoong@gmail.com>2026-07-07 15:04:49 -0700
committerMiklos Szeredi <mszeredi@redhat.com>2026-07-08 11:12:48 +0200
commit03e1dd35c206f24b6bc987198ac58e5138176cb7 (patch)
treea2a4695e1b90cb914053e6cb29211c7c631eb93d /include
parentcc6f804e785f9a7c04333cb55372723da482ae3f (diff)
downloadlinux-03e1dd35c206f24b6bc987198ac58e5138176cb7.tar.gz
linux-03e1dd35c206f24b6bc987198ac58e5138176cb7.zip
iomap: add helper to mark folio uptodate
Add an exported helper iomap_folio_mark_uptodate() to mark a folio as uptodate and update its uptodate bitmap if the folio has iomap state data attached. This is needed because there are some filesystems (eg fuse) that have paths outside of conventional iomap calls that need to mark a folio as uptodate (eg writing server-pushed data directly into the page cache) and need the iomap-internal uptodate bitmap to be in sync with the uptodate state of the folio. Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Darrick J. Wong <djwong@kernel.org> Signed-off-by: Joanne Koong <joannelkoong@gmail.com> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/iomap.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/iomap.h b/include/linux/iomap.h
index 56b43d594e6e..40aa3476a351 100644
--- a/include/linux/iomap.h
+++ b/include/linux/iomap.h
@@ -365,6 +365,7 @@ struct folio *iomap_get_folio(struct iomap_iter *iter, loff_t pos, size_t len);
bool iomap_release_folio(struct folio *folio, gfp_t gfp_flags);
void iomap_invalidate_folio(struct folio *folio, size_t offset, size_t len);
bool iomap_dirty_folio(struct address_space *mapping, struct folio *folio);
+void iomap_folio_mark_uptodate(struct folio *folio);
int iomap_file_unshare(struct inode *inode, loff_t pos, loff_t len,
const struct iomap_ops *ops,
const struct iomap_write_ops *write_ops);