linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/7] nfsd: implement the "delstid" draft
@ 2024-08-26 12:46 Jeff Layton
  2024-08-26 12:46 ` [PATCH v2 1/7] nfsd: add pragma public to delegated timestamp types Jeff Layton
                   ` (6 more replies)
  0 siblings, 7 replies; 10+ messages in thread
From: Jeff Layton @ 2024-08-26 12:46 UTC (permalink / raw)
  To: Chuck Lever, Neil Brown, Olga Kornievskaia, Dai Ngo, Tom Talpey,
	Trond Myklebust, Anna Schumaker, Olga Kornievskaia,
	Alexander Viro, Christian Brauner, Jan Kara, Jonathan Corbet
  Cc: Tom Haynes, linux-kernel, linux-nfs, linux-fsdevel, linux-doc,
	Jeff Layton

This adds support for most of the "delstid" draft:

    https://datatracker.ietf.org/doc/draft-ietf-nfsv4-delstid/06/

This includes a number of new features around the OPEN call:

- support for FATTR4_OPEN_ARGUMENTS: A new way for clients to discover
  what OPEN features the server supports at mount time.

- support for OPEN_XOR_DELEGATION: The server can send only a delegation
  stateid in response to an OPEN (avoiding the useless open stateid in
  that case).

- support for delegated timestamps: when the client holds a write
  delegation, it can send an updated atime and mtime in the CB_GETATTR
  response

FATTR4_OFFLINE is not implemented, since we don't have a way to
designate that under Linux. [1]

This patchset depends on a number of patchsets still in flight:
- the multigrain timestamp series [2] (in Christian's vfs.mgtime branch)
- the nfsd CB_GETATTR fixes [3][4] (in Chuck's nfsd-fixes branch)
- Chuck's xdrgen patches [5] (in Chuck's lkxdrgen branch)

If you want to test this functionality, you'll also need client-side
patches that went into v6.11-rc5 [6][7].

I should make special mention of patch #2, which starts integrating the
xdrgenerated header. That will affect both the client and server, so I
want to make sure everyone (Trond and Anna, in particular) is on board
with this scheme before we merge it.

For now, that patch just moves the header from where it was in Chuck's
tree, but it'd probably be better to add a new "make xdrgen" target for
that, long term.

[1]: We could add a STATX_ATTR_OFFLINE flag for this, but the userland
     use-cases are not 100% clear to me.
[2]: https://lore.kernel.org/linux-fsdevel/20240715-mgtime-v6-0-48e5d34bd2ba@kernel.org/
[3]: https://lore.kernel.org/linux-nfs/Zsoe%2FD24xvLfKClT@tissot.1015granger.net/T/#t
[4]: https://lore.kernel.org/linux-nfs/ZsofUUJeB1wbONyi@tissot.1015granger.net/T/#t
[5]: https://lore.kernel.org/linux-nfs/20240820144600.189744-1-cel@kernel.org/T/#me0207d0b18c19ddbf1cf698acff7e591bb4b100c
[6]: https://lore.kernel.org/linux-nfs/20240815141841.29620-1-jlayton@kernel.org/
[7]: https://lore.kernel.org/linux-nfs/20240821-nfs-6-11-v2-1-44478efe1650@kernel.org/

Signed-off-by: Jeff Layton <jlayton@kernel.org>
---
Changes in v2:
- rebase onto Chuck's lkxdrgen branch, and reworked how autogenerated
  code is included
- declare nfsd_open_arguments as a global, so it doesn't have to be
  set up on the stack each time
- delegated timestamp support has been added
- Link to v1: https://lore.kernel.org/r/20240816-delstid-v1-0-c221c3dc14cd@kernel.org

---
Jeff Layton (7):
      nfsd: add pragma public to delegated timestamp types
      nfs_common: make nfs4.h include generated nfs4_1.h
      nfsd: add support for FATTR4_OPEN_ARGUMENTS
      nfsd: implement OPEN_ARGS_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION
      fs: add an ATTR_CTIME_DLG flag
      nfsd: drop the ncf_cb_bmap field
      nfsd: add support for delegated timestamps

 {fs/nfsd => Documentation/sunrpc/xdr}/nfs4_1.x     |   2 +
 fs/attr.c                                          |  10 +-
 fs/nfsd/Makefile                                   |   2 +-
 fs/nfsd/nfs4callback.c                             |  43 +++++++-
 fs/nfsd/nfs4state.c                                | 115 +++++++++++++++++++--
 fs/nfsd/nfs4xdr.c                                  |  53 +++++++++-
 fs/nfsd/nfs4xdr_gen.c                              |  12 +--
 fs/nfsd/nfsd.h                                     |   6 +-
 fs/nfsd/state.h                                    |   4 +-
 fs/nfsd/xdr4cb.h                                   |  10 +-
 include/linux/fs.h                                 |   1 +
 include/linux/nfs4.h                               |   7 +-
 include/linux/nfs_xdr.h                            |   5 -
 .../linux/sunrpc/xdrgen/nfs4_1.h                   |  14 ++-
 include/uapi/linux/nfs4.h                          |   7 +-
 15 files changed, 244 insertions(+), 47 deletions(-)
---
base-commit: 55f9aa30de14b6ec52940adeb4790c15247fed40
change-id: 20240815-delstid-93290691ad11

Best regards,
-- 
Jeff Layton <jlayton@kernel.org>


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

end of thread, other threads:[~2024-08-26 13:16 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-08-26 12:46 [PATCH v2 0/7] nfsd: implement the "delstid" draft Jeff Layton
2024-08-26 12:46 ` [PATCH v2 1/7] nfsd: add pragma public to delegated timestamp types Jeff Layton
2024-08-26 12:46 ` [PATCH v2 2/7] nfs_common: make nfs4.h include generated nfs4_1.h Jeff Layton
2024-08-26 12:46 ` [PATCH v2 3/7] nfsd: add support for FATTR4_OPEN_ARGUMENTS Jeff Layton
2024-08-26 12:46 ` [PATCH v2 4/7] nfsd: implement OPEN_ARGS_SHARE_ACCESS_WANT_OPEN_XOR_DELEGATION Jeff Layton
2024-08-26 12:46 ` [PATCH v2 5/7] fs: add an ATTR_CTIME_DLG flag Jeff Layton
2024-08-26 13:08   ` Christian Brauner
2024-08-26 13:16     ` Jeff Layton
2024-08-26 12:46 ` [PATCH v2 6/7] nfsd: drop the ncf_cb_bmap field Jeff Layton
2024-08-26 12:46 ` [PATCH v2 7/7] nfsd: add support for delegated timestamps Jeff Layton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).