diff options
| author | 2025-01-26 16:50:18 -0500 | |
|---|---|---|
| committer | 2025-03-10 09:10:56 -0400 | |
| commit | 370345b4bd184a49ac68d6591801e5e3605b355a (patch) | |
| tree | bcf6b0aa3a0080e8a693a1052d492bf6dedb66a5 /include/uapi/linux/android/ssh:/git@git.zx2c4.com | |
| parent | NFSD: nfsd_unlink() clobbers non-zero status returned from fh_fill_pre_attrs() (diff) | |
NFSD: Never return NFS4ERR_FILE_OPEN when removing a directory
RFC 8881 Section 18.25.4 paragraph 5 tells us that the server
should return NFS4ERR_FILE_OPEN only if the target object is an
opened file. This suggests that returning this status when removing
a directory will confuse NFS clients.
This is a version-specific issue; nfsd_proc_remove/rmdir() and
nfsd3_proc_remove/rmdir() already return nfserr_access as
appropriate.
Unfortunately there is no quick way for nfsd4_remove() to determine
whether the target object is a file or not, so the check is done in
in nfsd_unlink() for now.
Reported-by: Trond Myklebust <trondmy@hammerspace.com>
Fixes: 466e16f0920f ("nfsd: check for EBUSY from vfs_rmdir/vfs_unink.")
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Cc: stable@vger.kernel.org
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Diffstat (limited to 'include/uapi/linux/android/ssh:/git@git.zx2c4.com')
0 files changed, 0 insertions, 0 deletions
