On 01.07.2016 22:08, David Miller wrote: > > People who use PACKET_FANOUT_HASH want a symmetric hash, meaning that > they want packets going in both directions on a flow to hash to the > same bucket. > > The core kernel SKB hash became non-symmetric when the ipv6 flow label > and other entities were incorporated into the standard flow hash order > to increase entropy. > > But there are no users of PACKET_FANOUT_HASH who want an assymetric > hash, they all want a symmetric one. > > Therefore, use the flow dissector to compute a flat symmetric hash > over only the protocol, addresses and ports. This hash does not get > installed into and override the normal skb hash, so this change has > no effect whatsoever on the rest of the stack. > > Reported-by: Eric Leblond <e...@regit.org> > Tested-by: Eric Leblond <e...@regit.org> > Signed-off-by: David S. Miller <da...@davemloft.net> > --- > > I'll be pushing this to -stable branches as well.
Acked-by: Hannes Frederic Sowa <han...@stressinduktion.org> Actually a funny trick I learned from DragonflyBSD sources is to just randomize the first two bytes of the rss key and replicate them to fill up the the last 38 bytes (or more). Doing so makes the rss hash generation on the networking card symmetric [1]. Bye, Hannes [1] http://gitweb.dragonflybsd.org/dragonfly.git/blob/HEAD:/sys/net/toeplitz.c#l41