Skip to content

net: tcp: make txhash use consistent for IPv4

Antoine Tenart netdev 2 versions – Applied

Status from this message: This series was applied to netdev/net-next.git (main)

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest3 patches 0 repliesApplied 3/3
  2. v14 patches 15 repliesSuperseded

Changes in v2 from the cover letter

- Rebased on top of latest net-next (one minor conflict).
- Dropped patch 4/4 ("net: skbuff: fix l4_hash comment") as we didn't come to an agreement, thread for reference:
https://lore.kernel.org/all/[email protected]/

Patches in v2 All 3 applied

#Subject and filesSizeRepliesApplied
1/3net: tcp: make the txhash available in TIME_WAIT sockets for IPv4 toonet/ipv4/tcp_minisocks.c+1 -10 repliesApplied
2/3net: ipv4: use consistent txhash in TIME_WAIT and SYN_RECVinclude/net/ip.h net/ipv4/ip_output.c net/ipv4/tcp_ipv4.c+13 -70 repliesApplied
3/3Documentation: net: net.core.txrehash is not specific to listening socketsDocumentation/admin-guide/sysctl/net.rst+2 -20 repliesApplied

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchEric Dumazet
1/3R-b
2/3R-b
3/3R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH net-next v2 0/3] net: tcp: make txhash use consistent for IPv4

Hello,

Series is divided in two parts. First two commits make the txhash (used for the skb hash in TCP) to be consistent for all IPv4/TCP packets (IPv6 doesn't have the same issue). Last commit improve a hash-related doc.

One example is when using OvS with dp_hash, which uses skb->hash, to select a path. We'd like packets from the same flow to be consistent, as well as the hash being stable over time when using net.core.txrehash=0. Same applies for kernel ECMP which also can use skb->hash.

Thanks!
Antoine

Since v1:
- Rebased on top of latest net-next (one minor conflict).
- Dropped patch 4/4 ("net: skbuff: fix l4_hash comment") as we didn't come to an agreement, thread for reference:
https://lore.kernel.org/all/[email protected]/

Antoine Tenart (3):
net: tcp: make the txhash available in TIME_WAIT sockets for IPv4 too
net: ipv4: use consistent txhash in TIME_WAIT and SYN_RECV
Documentation: net: net.core.txrehash is not specific to listening
sockets

 Documentation/admin-guide/sysctl/net.rst |  4 ++--
 include/net/ip.h                         |  2 +-
 net/ipv4/ip_output.c                     |  4 +++-
 net/ipv4/tcp_ipv4.c                      | 14 +++++++++-----
 net/ipv4/tcp_minisocks.c                 |  2 +-
 5 files changed, 16 insertions(+), 10 deletions(-)
Signature · 1 line
2.40.1