]> git.baikalelectronics.ru Git - kernel.git/commit
net: gro: change GRO overflow strategy
authorEric Dumazet <edumazet@google.com>
Thu, 9 Jan 2014 22:12:19 +0000 (14:12 -0800)
committerDavid S. Miller <davem@davemloft.net>
Mon, 13 Jan 2014 19:43:46 +0000 (11:43 -0800)
commitb5ba809c1ee6540ead5c06dcb9abc25e4d9e5de9
treec165e3f973dd98b731fbdd771c5eb751af475b77
parent92499b078a1100bc84f2a8f3d18799613240f84d
net: gro: change GRO overflow strategy

GRO layer has a limit of 8 flows being held in GRO list,
for performance reason.

When a packet comes for a flow not yet in the list,
and list is full, we immediately give it to upper
stacks, lowering aggregation performance.

With TSO auto sizing and FQ packet scheduler, this situation
happens more often.

This patch changes strategy to simply evict the oldest flow of
the list. This works better because of the nature of packet
trains for which GRO is efficient. This also has the effect
of lowering the GRO latency if many flows are competing.

Tested :

Used a 40Gbps NIC, with 4 RX queues, and 200 concurrent TCP_STREAM
netperf.

Before patch, aggregate rate is 11Gbps (while a single flow can reach
30Gbps)

After patch, line rate is reached.

Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: Jerry Chu <hkchu@google.com>
Cc: Neal Cardwell <ncardwell@google.com>
Acked-by: Neal Cardwell <ncardwell@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/core/dev.c