diff options
author | Steffen Klassert <steffen.klassert@secunet.com> | 2020-07-14 11:39:58 +0200 |
---|---|---|
committer | Steffen Klassert <steffen.klassert@secunet.com> | 2020-07-14 11:42:03 +0200 |
commit | 910a71ed772aac3bf228e8679f000b1505c287fb (patch) | |
tree | 57724545e14bac9d1d36eeef7cd213abc7cb0db1 /net/ipv4 | |
parent | 2d4c7986dbc6f78043df7b946b36996fca8c046f (diff) | |
parent | e98e44562ba2ee994f4fd1e32be7e327edd263ca (diff) | |
download | linux-910a71ed772aac3bf228e8679f000b1505c287fb.tar.gz |
Merge remote-tracking branch 'origin/testing'
Eyal Birger says:
====================
When having many xfrm interfaces, the linear lookup of devices based on
if_id becomes costly.
The first patch refactors xfrmi_decode_session() to use the xi used in
the netdevice priv context instead of looking it up in the list based
on ifindex. This is needed in order to use if_id as the only key used
for xi lookup.
The second patch extends the existing infrastructure - which already
stores the xfrmi contexts in an array of lists - to use a hash of the
if_id.
Example benchmarks:
- running on a KVM based VM
- xfrm tunnel mode between two namespaces
- xfrm interface in one namespace (10.0.0.2)
Before this change set:
Single xfrm interface in namespace:
$ netperf -H 10.0.0.2 -l8 -I95,10 -t TCP_STREAM
MIGRATED TCP STREAM TEST from 0.0.0.0 (0.0.0.0) port 0 AF_INET to 10.0.0.2 () port 0 AF_INET : +/-5.000% @ 95% conf. : demo
Recv Send Send
Socket Socket Message Elapsed
Size Size Size Time Throughput
bytes bytes bytes secs. 10^6bits/sec
131072 16384 16384 8.00 298.36
After adding 400 xfrmi interfaces in the same namespace:
$ netperf -H 10.0.0.2 -l8 -I95,10 -t TCP_STREAM
MIGRATED TCP STREAM TEST from 0.0.0.0 (0.0.0.0) port 0 AF_INET to 10.0.0.2 () port 0 AF_INET : +/-5.000% @ 95% conf. : demo
Recv Send Send
Socket Socket Message Elapsed
Size Size Size Time Throughput
bytes bytes bytes secs. 10^6bits/sec
131072 16384 16384 8.00 221.77
After this patchset there was no observed change after adding the
xfrmi interfaces.
====================
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
Diffstat (limited to 'net/ipv4')
0 files changed, 0 insertions, 0 deletions