diff options
-rw-r--r-- | net/ceph/messenger.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/net/ceph/messenger.c b/net/ceph/messenger.c index 4d111fd2b492..3b386674e34c 100644 --- a/net/ceph/messenger.c +++ b/net/ceph/messenger.c | |||
@@ -561,7 +561,7 @@ void ceph_con_open(struct ceph_connection *con, | |||
561 | mutex_lock(&con->mutex); | 561 | mutex_lock(&con->mutex); |
562 | dout("con_open %p %s\n", con, ceph_pr_addr(&addr->in_addr)); | 562 | dout("con_open %p %s\n", con, ceph_pr_addr(&addr->in_addr)); |
563 | 563 | ||
564 | BUG_ON(con->state != CON_STATE_CLOSED); | 564 | WARN_ON(con->state != CON_STATE_CLOSED); |
565 | con->state = CON_STATE_PREOPEN; | 565 | con->state = CON_STATE_PREOPEN; |
566 | 566 | ||
567 | con->peer_name.type = (__u8) entity_type; | 567 | con->peer_name.type = (__u8) entity_type; |
@@ -1509,7 +1509,7 @@ static int process_banner(struct ceph_connection *con) | |||
1509 | static void fail_protocol(struct ceph_connection *con) | 1509 | static void fail_protocol(struct ceph_connection *con) |
1510 | { | 1510 | { |
1511 | reset_connection(con); | 1511 | reset_connection(con); |
1512 | BUG_ON(con->state != CON_STATE_NEGOTIATING); | 1512 | WARN_ON(con->state != CON_STATE_NEGOTIATING); |
1513 | con->state = CON_STATE_CLOSED; | 1513 | con->state = CON_STATE_CLOSED; |
1514 | } | 1514 | } |
1515 | 1515 | ||
@@ -1635,7 +1635,7 @@ static int process_connect(struct ceph_connection *con) | |||
1635 | return -1; | 1635 | return -1; |
1636 | } | 1636 | } |
1637 | 1637 | ||
1638 | BUG_ON(con->state != CON_STATE_NEGOTIATING); | 1638 | WARN_ON(con->state != CON_STATE_NEGOTIATING); |
1639 | con->state = CON_STATE_OPEN; | 1639 | con->state = CON_STATE_OPEN; |
1640 | 1640 | ||
1641 | con->peer_global_seq = le32_to_cpu(con->in_reply.global_seq); | 1641 | con->peer_global_seq = le32_to_cpu(con->in_reply.global_seq); |
@@ -2132,7 +2132,6 @@ more: | |||
2132 | if (ret < 0) | 2132 | if (ret < 0) |
2133 | goto out; | 2133 | goto out; |
2134 | 2134 | ||
2135 | BUG_ON(con->state != CON_STATE_CONNECTING); | ||
2136 | con->state = CON_STATE_NEGOTIATING; | 2135 | con->state = CON_STATE_NEGOTIATING; |
2137 | 2136 | ||
2138 | /* | 2137 | /* |
@@ -2160,7 +2159,7 @@ more: | |||
2160 | goto more; | 2159 | goto more; |
2161 | } | 2160 | } |
2162 | 2161 | ||
2163 | BUG_ON(con->state != CON_STATE_OPEN); | 2162 | WARN_ON(con->state != CON_STATE_OPEN); |
2164 | 2163 | ||
2165 | if (con->in_base_pos < 0) { | 2164 | if (con->in_base_pos < 0) { |
2166 | /* | 2165 | /* |
@@ -2382,7 +2381,7 @@ static void ceph_fault(struct ceph_connection *con) | |||
2382 | dout("fault %p state %lu to peer %s\n", | 2381 | dout("fault %p state %lu to peer %s\n", |
2383 | con, con->state, ceph_pr_addr(&con->peer_addr.in_addr)); | 2382 | con, con->state, ceph_pr_addr(&con->peer_addr.in_addr)); |
2384 | 2383 | ||
2385 | BUG_ON(con->state != CON_STATE_CONNECTING && | 2384 | WARN_ON(con->state != CON_STATE_CONNECTING && |
2386 | con->state != CON_STATE_NEGOTIATING && | 2385 | con->state != CON_STATE_NEGOTIATING && |
2387 | con->state != CON_STATE_OPEN); | 2386 | con->state != CON_STATE_OPEN); |
2388 | 2387 | ||