ceph: allow closing session in restarting/reconnect state
authorYan, Zheng <zyan@redhat.com>
Thu, 25 Jul 2019 12:16:41 +0000 (20:16 +0800)
committerIlya Dryomov <idryomov@gmail.com>
Mon, 16 Sep 2019 10:06:23 +0000 (12:06 +0200)
CEPH_MDS_SESSION_{RESTARTING,RECONNECTING} are for for mds failover,
they are sub-states of CEPH_MDS_SESSION_OPEN. So __close_session()
should send close request for session in these two state.

Signed-off-by: "Yan, Zheng" <zyan@redhat.com>
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
fs/ceph/mds_client.h

index f7c8603484fef7be90184d0cc2dadede5474030e..810fd8689dfff6a19fd1ad941bf991c89e476c48 100644 (file)
@@ -148,9 +148,9 @@ enum {
        CEPH_MDS_SESSION_OPENING = 2,
        CEPH_MDS_SESSION_OPEN = 3,
        CEPH_MDS_SESSION_HUNG = 4,
-       CEPH_MDS_SESSION_CLOSING = 5,
-       CEPH_MDS_SESSION_RESTARTING = 6,
-       CEPH_MDS_SESSION_RECONNECTING = 7,
+       CEPH_MDS_SESSION_RESTARTING = 5,
+       CEPH_MDS_SESSION_RECONNECTING = 6,
+       CEPH_MDS_SESSION_CLOSING = 7,
        CEPH_MDS_SESSION_REJECTED = 8,
 };