diff options
| author | Chuck Lever <cel@kernel.org> | 2026-07-28 12:59:11 -0400 |
|---|---|---|
| committer | Chuck Lever <cel@kernel.org> | 2026-08-26 16:41:31 -0400 |
| commit | 9b910f445eadb97585989f06d14eaa552f013f27 (patch) | |
| tree | fb851e9c867ba352c553051e0d17189e7766988c /scripts/objdiff | |
| parent | 9f33dcebed7351cd0028376249cb98615fa0f82c (diff) | |
| download | linux-next-9b910f445eadb97585989f06d14eaa552f013f27.tar.gz linux-next-9b910f445eadb97585989f06d14eaa552f013f27.zip | |
NFSD: Don't apply NFS version-specific behavior to LOCALIO requests
LOCALIO serves NFS clients of every version through one entry point,
so no protocol version is associated with such a request.
nfsd_set_fh_dentry() selects version-specific behavior anyway: its
switch keys off fh_maxsize, and nfsd_open_local_fh() passes
NFS4_FHSIZE because that is the size of the buffer it copies into, so
LOCALIO lands in the NFSv4 arm. fh_getattr() keys off fh_maxsize too
and does run on a LOCALIO open, adding STATX_BTIME and
STATX_CHANGE_COOKIE to the mask it requests: work on filesystems that
compute them for a caller that never reads them.
nfsd_open_local_fh() only verifies a handle it received, so it has no
maximum size to state. Pass NFSD_FHSIZE_UNSPEC as nlm_fopen() already
does, which selects the switch arm that applies no version-specific
behavior, and state the bound on the copy out of struct nfs_fh as
NFS_MAXFHSIZE.
Suggested-by: NeilBrown <neil@brown.name>
Reviewed-by: NeilBrown <neil@brown.name>
Reviewed-by: Mike Snitzer <snitzer@kernel.org>
Link: https://patch.msgid.link/20260728165911.462534-6-cel@kernel.org
Signed-off-by: Chuck Lever <cel@kernel.org>
Diffstat (limited to 'scripts/objdiff')
0 files changed, 0 insertions, 0 deletions
