linux/drivers/net
Jason Wang 5503fcecd4 tun: rx batching
We can only process 1 packet at one time during sendmsg(). This often
lead bad cache utilization under heavy load. So this patch tries to do
some batching during rx before submitting them to host network
stack. This is done through accepting MSG_MORE as a hint from
sendmsg() caller, if it was set, batch the packet temporarily in a
linked list and submit them all once MSG_MORE were cleared.

Tests were done by pktgen (burst=128) in guest over mlx4(noqueue) on host:

                                 Mpps  -+%
    rx-frames = 0                0.91  +0%
    rx-frames = 4                1.00  +9.8%
    rx-frames = 8                1.00  +9.8%
    rx-frames = 16               1.01  +10.9%
    rx-frames = 32               1.07  +17.5%
    rx-frames = 48               1.07  +17.5%
    rx-frames = 64               1.08  +18.6%
    rx-frames = 64 (no MSG_MORE) 0.91  +0%

User were allowed to change per device batched packets through
ethtool -C rx-frames. NAPI_POLL_WEIGHT were used as upper limitation
to prevent bh from being disabled too long.

Signed-off-by: Jason Wang <jasowang@redhat.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-01-18 16:35:30 -05:00
..
appletalk net/appletalk: Fix kernel memory disclosure 2017-01-09 16:34:39 -05:00
arcnet
bonding net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
caif
can ktime: Cleanup ktime_set() usage 2016-12-25 17:21:22 +01:00
cris net: cris: make eth_v10.c explicitly non-modular 2016-10-31 20:58:34 -04:00
dsa net: dsa: mv88e6xxx: add EEPROM support to 6390 2017-01-13 20:17:01 -05:00
ethernet net:add one common config ARCH_WANT_RELAX_ORDER to support relax ordering 2017-01-18 16:33:00 -05:00
fddi fddi: skfp: Use more common logging styles 2016-12-29 11:37:14 -05:00
fjes net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
hamradio Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
hippi Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
hyperv Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-01-17 15:19:37 -05:00
ieee802154 ieee802154: atusb: fix driver to work with older firmware versions 2017-01-12 22:12:43 +01:00
ipvlan ipvlan: fix dev_id creation corner case. 2017-01-16 14:04:43 -05:00
irda Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
phy Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-01-17 15:19:37 -05:00
plip
ppp net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
slip net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
team net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
usb Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-01-17 15:19:37 -05:00
vmxnet3 net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
wan net: wan: slic_ds26522: fix spelling mistake: "configurated" -> "configured" 2016-12-28 15:12:20 -05:00
wimax net: use core MTU range checking in wireless drivers 2016-10-20 14:51:08 -04:00
wireless For 4.11, we seem to have more than in the past few releases: 2017-01-14 12:02:15 -05:00
xen-netback xen: features and fixes for 4.10 rc0 2016-12-13 16:07:55 -08:00
Kconfig
LICENSE.SRC
Makefile
Space.c
dummy.c net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
eql.c Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
geneve.c geneve: avoid use-after-free of skb->data 2016-12-02 14:07:11 -05:00
gtp.c gtp: Fix initialization of Flags octet in GTPv1 header 2016-12-17 12:00:25 -05:00
ifb.c net-tc: convert tc_from to tc_from_ingress and tc_redirected 2017-01-08 20:58:52 -05:00
loopback.c net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
macsec.c net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
macvlan.c net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
macvtap.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs 2016-12-16 10:24:44 -08:00
mdio.c net: mdio: add mdio45_ethtool_ksettings_get 2017-01-02 16:59:10 -05:00
mii.c net: mii: report 0 for unknown lp_advertising 2016-11-09 20:26:58 -05:00
netconsole.c
nlmon.c net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
ntb_netdev.c net: use core MTU range checking in core net infra 2016-10-20 14:51:09 -04:00
rionet.c net: use core MTU range checking in misc drivers 2016-10-20 14:51:10 -04:00
sb1000.c Replace <asm/uaccess.h> with <linux/uaccess.h> globally 2016-12-24 11:46:01 -08:00
sungem_phy.c
tun.c tun: rx batching 2017-01-18 16:35:30 -05:00
veth.c net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
virtio_net.c net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00
vrf.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-01-11 14:43:39 -05:00
vxlan.c vxlan: Set ports in flow key when doing route lookups 2017-01-11 16:09:47 -05:00
xen-netfront.c net: make ndo_get_stats64 a void function 2017-01-08 17:51:44 -05:00