Commit eaea34b
net/tun: implement ndo_set_rx_headroom
ndo_set_rx_headroom controls the align value used by tun devices to
allocate skbs on frame reception.
When the xmit device adds a large encapsulation, this avoids an skb
head reallocation on forwarding.
The measured improvement when forwarding towards a vxlan dev with
frame size below the egress device MTU is as follow:
vxlan over ipv6, bridged: +6%
vxlan over ipv6, ovs: +7%
In case of ipv4 tunnels there is no improvement, since the tun
device default alignment provides enough headroom to avoid the skb
head reallocation.
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>1 parent 3a927bc commit eaea34b
1 file changed
+16
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
187 | 187 | | |
188 | 188 | | |
189 | 189 | | |
| 190 | + | |
190 | 191 | | |
191 | 192 | | |
192 | 193 | | |
| |||
934 | 935 | | |
935 | 936 | | |
936 | 937 | | |
| 938 | + | |
| 939 | + | |
| 940 | + | |
| 941 | + | |
| 942 | + | |
| 943 | + | |
| 944 | + | |
| 945 | + | |
| 946 | + | |
| 947 | + | |
| 948 | + | |
937 | 949 | | |
938 | 950 | | |
939 | 951 | | |
| |||
945 | 957 | | |
946 | 958 | | |
947 | 959 | | |
| 960 | + | |
948 | 961 | | |
949 | 962 | | |
950 | 963 | | |
| |||
962 | 975 | | |
963 | 976 | | |
964 | 977 | | |
| 978 | + | |
965 | 979 | | |
966 | 980 | | |
967 | 981 | | |
| |||
1086 | 1100 | | |
1087 | 1101 | | |
1088 | 1102 | | |
1089 | | - | |
| 1103 | + | |
1090 | 1104 | | |
1091 | 1105 | | |
1092 | 1106 | | |
| |||
1694 | 1708 | | |
1695 | 1709 | | |
1696 | 1710 | | |
| 1711 | + | |
1697 | 1712 | | |
1698 | 1713 | | |
1699 | 1714 | | |
| |||
0 commit comments