aboutsummaryrefslogtreecommitdiff
path: root/fs/ceph/messenger.c
diff options
context:
space:
mode:
authorSage Weil <sage@newdream.net>2009-11-20 15:14:15 -0800
committerSage Weil <sage@newdream.net>2009-11-20 15:14:15 -0800
commit03c677e1d189ff62891d9f278c55bb798a418b81 (patch)
tree132c50a3b698c964625504ca833f08f161ffe0a5 /fs/ceph/messenger.c
parent0dc2570fab222affe7739b88b5ed04c511d433dc (diff)
ceph: reset msgr backoff during open, not after successful handshake
Reset the backoff delay when we reopen the connection, so that the delays for any initial connection problems are reasonable. We were resetting only after a successful handshake, which was of limited utility. Signed-off-by: Sage Weil <sage@newdream.net>
Diffstat (limited to 'fs/ceph/messenger.c')
-rw-r--r--fs/ceph/messenger.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/ceph/messenger.c b/fs/ceph/messenger.c
index 0b1674854b2..45cec31fdf5 100644
--- a/fs/ceph/messenger.c
+++ b/fs/ceph/messenger.c
@@ -348,6 +348,7 @@ void ceph_con_open(struct ceph_connection *con, struct ceph_entity_addr *addr)
set_bit(OPENING, &con->state);
clear_bit(CLOSED, &con->state);
memcpy(&con->peer_addr, addr, sizeof(*addr));
+ con->delay = 0; /* reset backoff memory */
queue_con(con);
}
@@ -1162,8 +1163,6 @@ static int process_connect(struct ceph_connection *con)
con->connect_seq);
WARN_ON(con->connect_seq !=
le32_to_cpu(con->in_reply.connect_seq));
-
- con->delay = 0; /* reset backoff memory */
prepare_read_tag(con);
break;