[PATCH 4/9] NFSD: Budget the CB_OFFLOAD opcode
Chuck Lever <[email protected]> Sun, 02 Aug 2026 13:04:31 -0400
| Newsgroups | gmane.linux.nfs |
|---|---|
| Message-ID | <20260802-nfsd-deleg-destroy-badhandle-v1-4-323aa7196055@kernel.org> |
NFS4_enc_cb_offload_sz counts the file handle, the stateid, and the offload information. encode_cb_offload4args() emits an opcode ahead of all three, so the macro falls one XDR word short. This macro sizes p_arglen and nothing else. rq_callsize pads that with two credential slacks, so the shortfall has never reached the send buffer. No backport is needed. Signed-off-by: Chuck Lever <[email protected]> --- fs/nfsd/xdr4cb.h | 1 + 1 file changed, 1 insertion(+) diff --git a/fs/nfsd/xdr4cb.h b/fs/nfsd/xdr4cb.h index 5285934b3a54..21d8280edead 100644 --- a/fs/nfsd/xdr4cb.h +++ b/fs/nfsd/xdr4cb.h @@ -58,6 +58,7 @@ XDR_QUADLEN(NFS4_VERIFIER_SIZE)) #define NFS4_enc_cb_offload_sz (cb_compound_enc_hdr_sz + \ cb_sequence_enc_sz + \ + op_enc_sz + \ enc_nfs4_fh_sz + \ enc_stateid_sz + \ enc_cb_offload_info_sz) -- 2.54.0