Skip to content

Commit 396ea16

Browse files
lxbszidryomov
authored andcommitted
ceph: remove incorrect session state check
Once the session is opened the s->s_ttl will be set, and when receiving a new mdsmap and the MDS map is changed, it will be possibly will close some sessions and open new ones. And then some sessions will be in CLOSING state evening without unmounting. URL: https://tracker.ceph.com/issues/54979 Signed-off-by: Xiubo Li <[email protected]> Reviewed-by: Jeff Layton <[email protected]> Signed-off-by: Ilya Dryomov <[email protected]>
1 parent 7f47f7f commit 396ea16

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

fs/ceph/mds_client.c

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4434,8 +4434,6 @@ static void maybe_recover_session(struct ceph_mds_client *mdsc)
44344434

44354435
bool check_session_state(struct ceph_mds_session *s)
44364436
{
4437-
struct ceph_fs_client *fsc = s->s_mdsc->fsc;
4438-
44394437
switch (s->s_state) {
44404438
case CEPH_MDS_SESSION_OPEN:
44414439
if (s->s_ttl && time_after(jiffies, s->s_ttl)) {
@@ -4444,10 +4442,6 @@ bool check_session_state(struct ceph_mds_session *s)
44444442
}
44454443
break;
44464444
case CEPH_MDS_SESSION_CLOSING:
4447-
/* Should never reach this when not force unmounting */
4448-
WARN_ON_ONCE(s->s_ttl &&
4449-
READ_ONCE(fsc->mount_state) != CEPH_MOUNT_SHUTDOWN);
4450-
fallthrough;
44514445
case CEPH_MDS_SESSION_NEW:
44524446
case CEPH_MDS_SESSION_RESTARTING:
44534447
case CEPH_MDS_SESSION_CLOSED:

0 commit comments

Comments
 (0)