RDS: TCP: Enable multipath RDS for TCP
Use RDS probe-ping to compute how many paths may be used with the peer, and to synchronously start the multiple paths. If mprds is supported, hash outgoing traffic to one of multiple paths in rds_sendmsg() when multipath RDS is supported by the transport. CC: Santosh Shilimkar <santosh.shilimkar@oracle.com> Signed-off-by: Sowmini Varadhan <sowmini.varadhan@oracle.com> Acked-by: Santosh Shilimkar <santosh.shilimkar@oracle.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
ac3615e7f3
commit
5916e2c155
@@ -81,6 +81,8 @@ static int rds_add_bound(struct rds_sock *rs, __be32 addr, __be16 *port)
|
||||
|
||||
if (*port != 0) {
|
||||
rover = be16_to_cpu(*port);
|
||||
if (rover == RDS_FLAG_PROBE_PORT)
|
||||
return -EINVAL;
|
||||
last = rover;
|
||||
} else {
|
||||
rover = max_t(u16, prandom_u32(), 2);
|
||||
@@ -91,12 +93,16 @@ static int rds_add_bound(struct rds_sock *rs, __be32 addr, __be16 *port)
|
||||
if (rover == 0)
|
||||
rover++;
|
||||
|
||||
if (rover == RDS_FLAG_PROBE_PORT)
|
||||
continue;
|
||||
key = ((u64)addr << 32) | cpu_to_be16(rover);
|
||||
if (rhashtable_lookup_fast(&bind_hash_table, &key, ht_parms))
|
||||
continue;
|
||||
|
||||
rs->rs_bound_key = key;
|
||||
rs->rs_bound_addr = addr;
|
||||
net_get_random_once(&rs->rs_hash_initval,
|
||||
sizeof(rs->rs_hash_initval));
|
||||
rs->rs_bound_port = cpu_to_be16(rover);
|
||||
rs->rs_bound_node.next = NULL;
|
||||
rds_sock_addref(rs);
|
||||
|
Reference in New Issue
Block a user