Linux NFS development
 help / color / mirror / Atom feed
* [PATCH v4 0/3] Initial NFS client support for RWF_DONTCACHE
@ 2025-08-19 14:18 Trond Myklebust
  2025-08-19 14:18 ` [PATCH v4 1/3] filemap: Add a helper for filesystems implementing dropbehind Trond Myklebust
                   ` (3 more replies)
  0 siblings, 4 replies; 10+ messages in thread
From: Trond Myklebust @ 2025-08-19 14:18 UTC (permalink / raw)
  To: Anna Schumaker; +Cc: linux-nfs, linux-fsdevel, Mike Snitzer, Matthew Wilcox

From: Trond Myklebust <trond.myklebust@hammerspace.com>

The following patch set attempts to add support for the RWF_DONTCACHE
flag in preadv2() and pwritev2() on NFS filesystems.

The main issue is allowing support on 2 stage writes (i.e. unstable
WRITE followed by a COMMIT) since those don't follow the current
assumption that the 'dropbehind' flag can be fulfilled as soon as the
writeback lock is dropped.

v2:
 - Make use of the new iocb parameter for nfs_write_begin()
v3:
 - Set/clear PG_DROPBEHIND on the head of the nfs_page group
 - Simplify helper folio_end_dropbehind
v4:
 - Replace filemap_end_dropbehind_write() with folio_end_dropbehind()
 - Add a helper to replace folio_end_writeback with an equivalent that
   does not attempt to interpret the dropbehind flag
 - Keep the folio dropbehind flag set until the NFS client is ready to
   call folio_end_dropbehind.
 - Don't try to do a read-modify-write in nfs_write_begin() if the folio
   has the dropbehind flag set.

Trond Myklebust (3):
  filemap: Add a helper for filesystems implementing dropbehind
  filemap: Add a version of folio_end_writeback that ignores dropbehind
  NFS: Enable use of the RWF_DONTCACHE flag on the NFS client

 fs/nfs/file.c           |  9 +++++----
 fs/nfs/nfs4file.c       |  1 +
 fs/nfs/write.c          |  4 +++-
 include/linux/pagemap.h |  2 ++
 mm/filemap.c            | 34 ++++++++++++++++++++++++++--------
 5 files changed, 37 insertions(+), 13 deletions(-)

-- 
2.50.1


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2025-09-10  1:59 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-19 14:18 [PATCH v4 0/3] Initial NFS client support for RWF_DONTCACHE Trond Myklebust
2025-08-19 14:18 ` [PATCH v4 1/3] filemap: Add a helper for filesystems implementing dropbehind Trond Myklebust
2025-08-19 14:25   ` Christoph Hellwig
2025-08-19 14:18 ` [PATCH v4 2/3] filemap: Add a version of folio_end_writeback that ignores dropbehind Trond Myklebust
2025-08-19 14:18 ` [PATCH v4 3/3] NFS: Enable use of the RWF_DONTCACHE flag on the NFS client Trond Myklebust
2025-09-06 16:48 ` [PATCH v5 0/3] Initial NFS client support for RWF_DONTCACHE Trond Myklebust
2025-09-06 16:48   ` [PATCH v5 1/3] filemap: Add a helper for filesystems implementing dropbehind Trond Myklebust
2025-09-06 16:48   ` [PATCH v5 2/3] filemap: Add a version of folio_end_writeback that ignores dropbehind Trond Myklebust
2025-09-06 16:48   ` [PATCH v5 3/3] NFS: Enable use of the RWF_DONTCACHE flag on the NFS client Trond Myklebust
2025-09-10  1:59   ` [PATCH v5 0/3] Initial NFS client support for RWF_DONTCACHE Trond Myklebust

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox