diff options
author | Chema Gonzalez <chema@google.com> | 2012-09-07 13:40:50 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-09-08 18:41:48 -0400 |
commit | 6862234238e84648c305526af2edd98badcad1e0 (patch) | |
tree | 00abc69781b91d27503baf76594e1914c1671eaf /include/asm-generic/param.h | |
parent | 777bf135b77071672662c67f0abffcf433450d68 (diff) | |
download | op-kernel-dev-6862234238e84648c305526af2edd98badcad1e0.zip op-kernel-dev-6862234238e84648c305526af2edd98badcad1e0.tar.gz |
net: small bug on rxhash calculation
In the current rxhash calculation function, while the
sorting of the ports/addrs is coherent (you get the
same rxhash for packets sharing the same 4-tuple, in
both directions), ports and addrs are sorted
independently. This implies packets from a connection
between the same addresses but crossed ports hash to
the same rxhash.
For example, traffic between A=S:l and B=L:s is hashed
(in both directions) from {L, S, {s, l}}. The same
rxhash is obtained for packets between C=S:s and D=L:l.
This patch ensures that you either swap both addrs and ports,
or you swap none. Traffic between A and B, and traffic
between C and D, get their rxhash from different sources
({L, S, {l, s}} for A<->B, and {L, S, {s, l}} for C<->D)
The patch is co-written with Eric Dumazet <edumazet@google.com>
Signed-off-by: Chema Gonzalez <chema@google.com>
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/asm-generic/param.h')
0 files changed, 0 insertions, 0 deletions