diff options
author | Trond Myklebust <trond.myklebust@hammerspace.com> | 2025-09-03 18:48:57 +0300 |
---|---|---|
committer | Trond Myklebust <trond.myklebust@hammerspace.com> | 2025-09-06 23:51:26 +0300 |
commit | b7b8574225e9d2b5f1fb5483886ab797892f43b5 (patch) | |
tree | 2924b4420caa76576c7c050f29e03e21870b857c /fs/nfs/write.c | |
parent | ca247c89900ae90207f4d321e260cd93b7c7d104 (diff) | |
download | linux-b7b8574225e9d2b5f1fb5483886ab797892f43b5.tar.xz |
NFS: nfs_invalidate_folio() must observe the offset and size arguments
If we're truncating part of the folio, then we need to write out the
data on the part that is not covered by the cancellation.
Fixes: d47992f86b30 ("mm: change invalidatepage prototype to accept length")
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Diffstat (limited to 'fs/nfs/write.c')
-rw-r--r-- | fs/nfs/write.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/nfs/write.c b/fs/nfs/write.c index 8b7c04737967..e359fbcdc8a0 100644 --- a/fs/nfs/write.c +++ b/fs/nfs/write.c @@ -2045,6 +2045,7 @@ int nfs_wb_folio_cancel(struct inode *inode, struct folio *folio) * release it */ nfs_inode_remove_request(req); nfs_unlock_and_release_request(req); + folio_cancel_dirty(folio); } return ret; |