From: Alexander Mikhalitsyn Date: Mon, 23 Oct 2023 12:34:26 +0000 (+0200) Subject: MClientRequest: handle ext_num_retry and ext_num_fwd from ceph_mds_request_head_legacy X-Git-Tag: v18.2.1~10 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=fb7ed63dca70716c5071d1ef34f1852fa7726e60;p=ceph.git MClientRequest: handle ext_num_retry and ext_num_fwd from ceph_mds_request_head_legacy When a client is too old and uses struct ceph_mds_request_head_legacy we must fill new ext_num_retry and ext_num_fwd fields from an old num_retry and num_fwd. Fixes: https://github.com/ceph/ceph/pull/45669 Fixes: https://tracker.ceph.com/issues/63288 Fixes: commit cbd7e3040208 ("ceph_fs.h: add 32 bits extended num_retry and num_fwd support") Signed-off-by: Alexander Mikhalitsyn (cherry picked from commit 43f32a46aa9095b19525357ba7ca215e842b4f77) (cherry picked from commit 312bb5b9f1ada9646205a78f0a0fcc73d2530d5c) --- diff --git a/src/messages/MClientRequest.h b/src/messages/MClientRequest.h index c62e183a75633..3c7d83ec11b36 100644 --- a/src/messages/MClientRequest.h +++ b/src/messages/MClientRequest.h @@ -234,6 +234,9 @@ public: copy_from_legacy_head(&head, &old_mds_head); head.version = 0; + head.ext_num_retry = head.num_retry; + head.ext_num_fwd = head.num_fwd; + /* Can't set the btime from legacy struct */ if (head.op == CEPH_MDS_OP_SETATTR) { int localmask = head.args.setattr.mask;