summaryrefslogtreecommitdiff
path: root/tools/lib/python
diff options
context:
space:
mode:
authorChuck Lever <cel@kernel.org>2026-09-16 12:28:52 -0400
committerChuck Lever <cel@kernel.org>2026-10-11 23:12:50 -0400
commit1ed756d42ce923537cff3e7bcd8959e3e258f883 (patch)
tree5e3d3f8557eaea4ae91ff1953b85291cb8f5bf43 /tools/lib/python
parentf4a4dbb14461728d2d9b2d9512192ff0e9179ce9 (diff)
downloadlinux-next-1ed756d42ce923537cff3e7bcd8959e3e258f883.tar.gz
linux-next-1ed756d42ce923537cff3e7bcd8959e3e258f883.zip
NFSD: Use xdrgen XDR functions for NFSv2 MKDIR procedure
Replace the NFSPROC_MKDIR entry in the nfsd_procedures2 array with an entry that dispatches the xdrgen-generated nfs_svc_decode_createargs and nfs_svc_encode_diropres. MKDIR reuses the createargs and diropres wrapper structures introduced for the CREATE conversion, which bridge the generated xdrgen types and the legacy svc_fh, iattr, and kstat representations the NFSD VFS layer still uses. The pc_argzero field is now set to zero for the NFSv2 MKDIR procedure. The xdrgen decoders are trusted to initialize all arguments in the argp->xdrgen field, making the early defensive memset unnecessary. The remaining argp fields are cleared as needed. This refactor replaces the use of svcxdr_encode_fattr(), so the references to the parent directory and the new object file handles can be released directly by nfsd_proc_mkdir(). A separate ->pc_release callback is thus no longer needed. This makes it straightforward to confirm that the file handles are properly released during every error flow. With CREATE and MKDIR both converted, nfssvc_decode_createargs(), nfssvc_encode_diropres(), and nfssvc_release_diropres() no longer have any callers, so they are removed, along with the svcxdr_decode_sattr() and svcxdr_encode_fhandle() helpers they relied on. The now-unused nfsd_createargs and nfsd_diropres structures are removed as well. Acked-by: Jeff Layton <jlayton@kernel.org> Link: https://patch.msgid.link/20260916162859.2051-24-cel@kernel.org Signed-off-by: Chuck Lever <cel@kernel.org>
Diffstat (limited to 'tools/lib/python')
0 files changed, 0 insertions, 0 deletions