diff options
Diffstat (limited to 'net/ceph')
-rw-r--r-- | net/ceph/messenger.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/net/ceph/messenger.c b/net/ceph/messenger.c index bcbd409b5ca7..cca3cf341d70 100644 --- a/net/ceph/messenger.c +++ b/net/ceph/messenger.c | |||
@@ -725,7 +725,6 @@ static int prepare_write_connect(struct ceph_messenger *msgr, | |||
725 | con->out_connect.protocol_version = cpu_to_le32(proto); | 725 | con->out_connect.protocol_version = cpu_to_le32(proto); |
726 | con->out_connect.flags = 0; | 726 | con->out_connect.flags = 0; |
727 | 727 | ||
728 | ceph_con_out_kvec_reset(con); | ||
729 | if (include_banner) | 728 | if (include_banner) |
730 | prepare_write_banner(msgr, con); | 729 | prepare_write_banner(msgr, con); |
731 | ceph_con_out_kvec_add(con, sizeof (con->out_connect), &con->out_connect); | 730 | ceph_con_out_kvec_add(con, sizeof (con->out_connect), &con->out_connect); |
@@ -1389,6 +1388,7 @@ static int process_connect(struct ceph_connection *con) | |||
1389 | return -1; | 1388 | return -1; |
1390 | } | 1389 | } |
1391 | con->auth_retry = 1; | 1390 | con->auth_retry = 1; |
1391 | ceph_con_out_kvec_reset(con); | ||
1392 | ret = prepare_write_connect(con->msgr, con, 0); | 1392 | ret = prepare_write_connect(con->msgr, con, 0); |
1393 | if (ret < 0) | 1393 | if (ret < 0) |
1394 | return ret; | 1394 | return ret; |
@@ -1409,6 +1409,7 @@ static int process_connect(struct ceph_connection *con) | |||
1409 | ENTITY_NAME(con->peer_name), | 1409 | ENTITY_NAME(con->peer_name), |
1410 | ceph_pr_addr(&con->peer_addr.in_addr)); | 1410 | ceph_pr_addr(&con->peer_addr.in_addr)); |
1411 | reset_connection(con); | 1411 | reset_connection(con); |
1412 | ceph_con_out_kvec_reset(con); | ||
1412 | prepare_write_connect(con->msgr, con, 0); | 1413 | prepare_write_connect(con->msgr, con, 0); |
1413 | prepare_read_connect(con); | 1414 | prepare_read_connect(con); |
1414 | 1415 | ||
@@ -1432,6 +1433,7 @@ static int process_connect(struct ceph_connection *con) | |||
1432 | le32_to_cpu(con->out_connect.connect_seq), | 1433 | le32_to_cpu(con->out_connect.connect_seq), |
1433 | le32_to_cpu(con->in_connect.connect_seq)); | 1434 | le32_to_cpu(con->in_connect.connect_seq)); |
1434 | con->connect_seq = le32_to_cpu(con->in_connect.connect_seq); | 1435 | con->connect_seq = le32_to_cpu(con->in_connect.connect_seq); |
1436 | ceph_con_out_kvec_reset(con); | ||
1435 | prepare_write_connect(con->msgr, con, 0); | 1437 | prepare_write_connect(con->msgr, con, 0); |
1436 | prepare_read_connect(con); | 1438 | prepare_read_connect(con); |
1437 | break; | 1439 | break; |
@@ -1446,6 +1448,7 @@ static int process_connect(struct ceph_connection *con) | |||
1446 | le32_to_cpu(con->in_connect.global_seq)); | 1448 | le32_to_cpu(con->in_connect.global_seq)); |
1447 | get_global_seq(con->msgr, | 1449 | get_global_seq(con->msgr, |
1448 | le32_to_cpu(con->in_connect.global_seq)); | 1450 | le32_to_cpu(con->in_connect.global_seq)); |
1451 | ceph_con_out_kvec_reset(con); | ||
1449 | prepare_write_connect(con->msgr, con, 0); | 1452 | prepare_write_connect(con->msgr, con, 0); |
1450 | prepare_read_connect(con); | 1453 | prepare_read_connect(con); |
1451 | break; | 1454 | break; |
@@ -1851,6 +1854,7 @@ more: | |||
1851 | 1854 | ||
1852 | /* open the socket first? */ | 1855 | /* open the socket first? */ |
1853 | if (con->sock == NULL) { | 1856 | if (con->sock == NULL) { |
1857 | ceph_con_out_kvec_reset(con); | ||
1854 | prepare_write_connect(msgr, con, 1); | 1858 | prepare_write_connect(msgr, con, 1); |
1855 | prepare_read_banner(con); | 1859 | prepare_read_banner(con); |
1856 | set_bit(CONNECTING, &con->state); | 1860 | set_bit(CONNECTING, &con->state); |