]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
ceph: don't update importing cap's mseq when handing cap export
authorYan, Zheng <zyan@redhat.com>
Thu, 29 Nov 2018 03:22:50 +0000 (11:22 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 13 Jan 2019 09:07:12 +0000 (10:07 +0100)
commit 3c1392d4c49962a31874af14ae9ff289cb2b3851 upstream.

Updating mseq makes client think importer mds has accepted all prior
cap messages and importer mds knows what caps client wants. Actually
some cap messages may have been dropped because of mseq mismatch.

If mseq is left untouched, importing cap's mds_wanted later will get
reset by cap import message.

Cc: stable@vger.kernel.org
Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/ceph/caps.c

index cefca661464b91a4edae048a8567e900d8560df6..7ed2bfedf142eaf29ad89e4ad45f88aa93a44b59 100644 (file)
@@ -2830,7 +2830,6 @@ retry:
                        tcap->cap_id = t_cap_id;
                        tcap->seq = t_seq - 1;
                        tcap->issue_seq = t_seq - 1;
-                       tcap->mseq = t_mseq;
                        tcap->issued |= issued;
                        tcap->implemented |= issued;
                        if (cap == ci->i_auth_cap)