Skip to content

Assortment of I/O fixes for the NFS client

Trond Myklebust linux-nfs 2 versions – New

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest8 patches 0 repliesNew
  2. v15 patches 3 repliesSuperseded

Changes in v2 from the cover letter

- Fix an off by one issue in nfs_write_begin()
- Address eof page pollution on copy offload and clone range (Thanks, Olga!)
- Address O_DIRECT ordering w.r.t. copy offload and clone range

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/8NFS: Protect against 'eof page pollution'fs/nfs/file.c fs/nfs/inode.c fs/nfs/internal.h +2 more+54 -50 replies
2/8NFSv4.2: Protect copy offload and clone against 'eof page pollution'fs/nfs/nfs42proc.c+13 -60 replies
3/8NFS: Serialise O_DIRECT i/o and truncate()fs/nfs/inode.c fs/nfs/internal.h fs/nfs/io.c+15 -120 replies
4/8NFSv4.2: Serialise O_DIRECT i/o and fallocate()fs/nfs/nfs42proc.c+1 -00 replies
5/8NFSv4.2: Serialise O_DIRECT i/o and clone rangefs/nfs/nfs4file.c+2 -00 replies
6/8NFSv4.2: Serialise O_DIRECT i/o and copy rangefs/nfs/nfs42proc.c+1 -00 replies
7/8NFS: nfs_invalidate_folio() must observe the offset and size argumentsfs/nfs/file.c fs/nfs/write.c+5 -30 replies
8/8NFS: Fix the marking of the folio as up to datefs/nfs/write.c+5 -470 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH v2 0/8] Assortment of I/O fixes for the NFS client

From: Trond Myklebust <[email protected]>

The following patch series addresses a series of issues that affect the NFS client's I/O path. The first patch is needed to fix a corner case when using mmap() to map the tail end of the file into memory, and then later extending the file length (see recent xfstests generic/363). The second set is used to ensure correct ordering of O_DIRECT operations with truncate + fallocate.
Finally, there are fixes to ensure folio invalidation is correct w.r.t. the VFS documentation, and a cleanup of the code that decides when a folio can be marked as up to date.

v2:
- Fix an off by one issue in nfs_write_begin()
- Address eof page pollution on copy offload and clone range (Thanks, Olga!)
- Address O_DIRECT ordering w.r.t. copy offload and clone range

Trond Myklebust (8):
NFS: Protect against 'eof page pollution'
NFSv4.2: Protect copy offload and clone against 'eof page pollution'
NFS: Serialise O_DIRECT i/o and truncate()
NFSv4.2: Serialise O_DIRECT i/o and fallocate()
NFSv4.2: Serialise O_DIRECT i/o and clone range
NFSv4.2: Serialise O_DIRECT i/o and copy range
NFS: nfs_invalidate_folio() must observe the offset and size arguments
NFS: Fix the marking of the folio as up to date

 fs/nfs/file.c      | 40 +++++++++++++++++++++++++++++++---
 fs/nfs/inode.c     | 13 +++++++++---
 fs/nfs/internal.h  | 12 +++++++++++
 fs/nfs/io.c        | 13 ++----------
 fs/nfs/nfs42proc.c | 35 ++++++++++++++++++++++--------
 fs/nfs/nfs4file.c  |  2 ++
 fs/nfs/nfstrace.h  |  1 +
 fs/nfs/write.c     | 53 ++++++----------------------------------------
 8 files changed, 96 insertions(+), 73 deletions(-)
Signature · 1 line
2.51.0