Dan Aloni reported a problem with the way NFSD's READ implementation deals with the very upper end of file sizes, and I got interested in how some of the other operations handled it. I found some issues, and have started a (growing) pile of patches to deal with them. Since at least the SETATTR case appears to cause a crash on some filesystems, I think several of these are 5.17-rc fodder (i.e., priority bug fixes). Dan's still working on the READ issue. Changes since RFC: - Series reordered so priority fixes come first - Setattr size check is now in a common function - Patch descriptions clarified --- Chuck Lever (5): NFSD: Fix ia_size underflow NFSD: Fix NFSv3 SETATTR/CREATE's handling of large file sizes NFSD: Clamp WRITE offsets NFSD: COMMIT operations must not return NFS?ERR_INVAL NFSD: Deprecate NFS_OFFSET_MAX fs/nfsd/nfs3proc.c | 21 ++++++++++++----- fs/nfsd/nfs3xdr.c | 4 ++-- fs/nfsd/nfs4proc.c | 5 ++-- fs/nfsd/nfs4xdr.c | 2 +- fs/nfsd/vfs.c | 57 +++++++++++++++++++++++++++++++-------------- fs/nfsd/vfs.h | 4 ++-- include/linux/nfs.h | 8 ------- 7 files changed, 63 insertions(+), 38 deletions(-) -- Chuck Lever