Skip to content

Commit 9d6c5c3

Browse files
kcp-gitgerd-rausch
authored andcommitted
rds: MPRDS messages delivered out of order
This reverts commit 9f85df8 as it causes out of order message delivery for MPRDS. Orabug: 28838065 Signed-off-by: Ka-Cheong Poon <[email protected]> Reviewed-by: Håkon Bugge <[email protected]>
1 parent 443de53 commit 9d6c5c3

File tree

1 file changed

+3
-10
lines changed

1 file changed

+3
-10
lines changed

net/rds/send.c

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1182,8 +1182,7 @@ static inline int rds_rdma_bytes(struct msghdr *msg, size_t *rdma_bytes)
11821182
return 0;
11831183
}
11841184

1185-
static int rds_send_mprds_hash(struct rds_sock *rs,
1186-
struct rds_connection *conn, int nonblock)
1185+
static int rds_send_mprds_hash(struct rds_sock *rs, struct rds_connection *conn)
11871186
{
11881187
int hash;
11891188

@@ -1199,16 +1198,10 @@ static int rds_send_mprds_hash(struct rds_sock *rs,
11991198
* used. But if we are interrupted, we have to use the zero
12001199
* c_path in case the connection ends up being non-MP capable.
12011200
*/
1202-
if (conn->c_npaths == 0) {
1203-
/* Cannot wait for the connection be made, so just use
1204-
* the base c_path.
1205-
*/
1206-
if (nonblock)
1207-
return 0;
1201+
if (conn->c_npaths == 0)
12081202
if (wait_event_interruptible(conn->c_hs_waitq,
12091203
conn->c_npaths != 0))
12101204
hash = 0;
1211-
}
12121205
if (conn->c_npaths == 1)
12131206
hash = 0;
12141207
}
@@ -1440,7 +1433,7 @@ int rds_sendmsg(struct socket *sock, struct msghdr *msg, size_t payload_len)
14401433
}
14411434

14421435
if (conn->c_trans->t_mp_capable)
1443-
cpath = &conn->c_path[rds_send_mprds_hash(rs, conn, nonblock)];
1436+
cpath = &conn->c_path[rds_send_mprds_hash(rs, conn)];
14441437
else
14451438
cpath = &conn->c_path[0];
14461439

0 commit comments

Comments
 (0)