aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv6/tcp_ipv6.c
diff options
context:
space:
mode:
authorEric Dumazet <[email protected]>2015-09-15 22:24:20 +0000
committerDavid S. Miller <[email protected]>2015-09-18 04:01:04 +0000
commit58d607d3e52f2b15902f58a1161da9fb3b0f6d47 (patch)
tree1949d88eb7d541878079ddafa607c31017099349 /net/ipv6/tcp_ipv6.c
parentMerge branch 'nf_hook_netns' (diff)
downloadkernel-58d607d3e52f2b15902f58a1161da9fb3b0f6d47.tar.gz
kernel-58d607d3e52f2b15902f58a1161da9fb3b0f6d47.zip
tcp: provide skb->hash to synack packets
In commit b73c3d0e4f0e ("net: Save TX flow hash in sock and set in skbuf on xmit"), Tom provided a l4 hash to most outgoing TCP packets. We'd like to provide one as well for SYNACK packets, so that all packets of a given flow share same txhash, to later enable bonding driver to also use skb->hash to perform slave selection. Note that a SYNACK retransmit shuffles the tx hash, as Tom did in commit 265f94ff54d62 ("net: Recompute sk_txhash on negative routing advice") for established sockets. This has nice effect making TCP flows resilient to some kind of black holes, even at connection establish phase. Signed-off-by: Eric Dumazet <[email protected]> Cc: Tom Herbert <[email protected]> Cc: Mahesh Bandewar <[email protected]> Acked-by: Tom Herbert <[email protected]> Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'net/ipv6/tcp_ipv6.c')
-rw-r--r--net/ipv6/tcp_ipv6.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c
index 97d9314ea361..f9c0e2640671 100644
--- a/net/ipv6/tcp_ipv6.c
+++ b/net/ipv6/tcp_ipv6.c
@@ -1090,7 +1090,7 @@ static struct sock *tcp_v6_syn_recv_sock(struct sock *sk, struct sk_buff *skb,
newsk->sk_v6_rcv_saddr = ireq->ir_v6_loc_addr;
newsk->sk_bound_dev_if = ireq->ir_iif;
- sk_set_txhash(newsk);
+ newsk->sk_txhash = tcp_rsk(req)->txhash;
/* Now IPv6 options...