linux_dsm_epyc7002/drivers/net/ethernet
Michal Schmidt aee77e4acc r8169: use unlimited DMA burst for TX
The r8169 driver currently limits the DMA burst for TX to 1024 bytes. I have
a box where this prevents the interface from using the gigabit line to its full
potential. This patch solves the problem by setting TX_DMA_BURST to unlimited.

The box has an ASRock B75M motherboard with on-board RTL8168evl/8111evl
(XID 0c900880). TSO is enabled.

I used netperf (TCP_STREAM test) to measure the dependency of TX throughput
on MTU. I did it for three different values of TX_DMA_BURST ('5'=512, '6'=1024,
'7'=unlimited). This chart shows the results:
http://michich.fedorapeople.org/r8169/r8169-effects-of-TX_DMA_BURST.png

Interesting points:
 - With the current DMA burst limit (1024):
   - at the default MTU=1500 I get only 842 Mbit/s.
   - when going from small MTU, the performance rises monotonically with
     increasing MTU only up to a peak at MTU=1076 (908 MBit/s). Then there's
     a sudden drop to 762 MBit/s from which the throughput rises monotonically
     again with further MTU increases.
 - With a smaller DMA burst limit (512):
   - there's a similar peak at MTU=1076 and another one at MTU=564.
 - With unlimited DMA burst:
   - at the default MTU=1500 I get nice 940 Mbit/s.
   - the throughput rises monotonically with increasing MTU with no strange
     peaks.

Notice that the peaks occur at MTU sizes that are multiples of the DMA burst
limit plus 52. Why 52? Because:
  20 (IP header) + 20 (TCP header) + 12 (TCP options) = 52

The Realtek-provided r8168 driver (v8.032.00) uses unlimited TX DMA burst too,
except for CFG_METHOD_1 where the TX DMA burst is set to 512 bytes.
CFG_METHOD_1 appears to be the oldest MAC version of "RTL8168B/8111B",
i.e. RTL_GIGA_MAC_VER_11 in r8169. Not sure if this MAC version really needs
the smaller burst limit, or if any other versions have similar requirements.

Signed-off-by: Michal Schmidt <mschmidt@redhat.com>
Acked-by: Francois Romieu <romieu@fr.zoreil.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2012-09-19 19:19:07 -04:00
..
3com drivers/net/ethernet: Fix (nearly-)kernel-doc comments for various functions 2012-07-10 23:13:46 -07:00
8390 net: add support for NS8390 based eth controllers on some ColdFire CPU boards 2012-07-12 07:54:45 -07:00
adaptec starfire: remove deprecated options. 2012-04-07 11:45:26 +02:00
adi bfin: Fix build failure due to get_ts_info() changes. 2012-04-06 00:17:50 -04:00
aeroflex ethernet: Remove casts to same type 2012-06-06 09:31:33 -07:00
alteon
amd lance: remove unnecessary setting of skb->dev 2012-07-10 23:24:56 -07:00
apple ethernet: Remove casts to same type 2012-06-06 09:31:33 -07:00
atheros atl1c: fix issue of io access mode for AR8152 v2.1 2012-07-20 11:21:18 -07:00
broadcom Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2012-09-15 11:43:53 -04:00
brocade drivers/net/ethernet: Fix non-kernel-doc comments with kernel-doc start markers 2012-07-10 23:13:46 -07:00
cadence net/macb: manage carrier state with call to netif_carrier_{on|off}() 2012-07-09 00:03:06 -07:00
calxeda net: calxedaxgmac: enable rx cut-thru mode 2012-07-10 23:25:47 -07:00
chelsio cxgb4: Remove duplicate register definitions 2012-09-05 17:41:40 -04:00
cirrus cs89x0 : packet reception not working 2012-08-31 15:48:56 -04:00
cisco enic: remove unnecessary setting of skb->dev 2012-07-10 23:24:56 -07:00
davicom dm9000: some coldfire boards need this 2012-05-14 18:40:16 -04:00
dec ethernet: Remove casts to same type 2012-06-06 09:31:33 -07:00
dlink Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2012-05-07 23:35:40 -04:00
emulex be2net: use PCIe AER capability 2012-09-05 17:49:28 -04:00
faraday net: ftgmac100/ftmac100: dont pull too much data 2012-07-18 09:40:53 -07:00
freescale Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2012-08-31 15:14:18 -04:00
fujitsu drivers/net: delete all code/drivers depending on CONFIG_MCA 2012-05-17 16:37:41 -04:00
hp ethernet: Remove casts to same type 2012-06-06 09:31:33 -07:00
i825xx i825xx: znet: fix compiler warnings when building a 64-bit kernel 2012-09-19 15:45:23 -04:00
ibm ibmveth: Fix alignment of rx queue bug 2012-09-05 17:45:23 -04:00
icplus
intel netdev: make address const in device address management 2012-09-19 16:35:22 -04:00
marvell Merge branch 'v3.5-rc7-fixes' of git://github.com/lunn/linux into fixes 2012-07-25 21:37:09 +02:00
mellanox net/mlx4_core: Return the error value in case of command initialization failure 2012-09-07 12:55:59 -04:00
micrel ethernet: Use eth_random_addr 2012-07-16 22:38:27 -07:00
microchip
myricom myri10ge: set maximal number of default RSS queues 2012-07-05 03:06:44 -07:00
natsemi drivers/net: delete all code/drivers depending on CONFIG_MCA 2012-05-17 16:37:41 -04:00
neterion net: fix race condition in several drivers when reading stats 2012-07-22 12:12:32 -07:00
nuvoton
nvidia forcedeth: prevent TX timeouts after reboot 2012-08-30 13:04:57 -04:00
nxp lpc_eth: remove obsolete ifdefs 2012-08-08 16:07:51 -07:00
octeon netdev: octeon_mgmt: Convert to use device tree. 2012-07-23 13:54:53 +01:00
oki-semi pch_gbe: vlan skb len fix 2012-07-26 14:30:23 -07:00
packetengines yellowfin: stop using net_device.{base_addr, irq}. 2012-04-07 11:45:26 +02:00
pasemi net/pasemi: fix compiler warning 2012-05-02 20:52:48 -04:00
qlogic qlge: Add offload features to vlan interfaces 2012-07-29 23:18:30 -07:00
racal
rdc r6040: use module_pci_driver macro 2012-07-09 14:42:30 -07:00
realtek r8169: use unlimited DMA burst for TX 2012-09-19 19:19:07 -04:00
renesas net: sh_eth: Add eth support for R8A7779 device 2012-08-20 02:16:54 -07:00
seeq |PATCH] seeq: Add missing spinlock init 2012-09-07 12:56:00 -04:00
sfc Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2012-08-31 15:14:18 -04:00
sgi ethernet: Remove casts to same type 2012-06-06 09:31:33 -07:00
silan sc92031: stop using net_device.{base_addr, irq} 2012-04-07 11:45:27 +02:00
sis sis900: stop using net_device.{base_addr, irq} and convert to __iomem. 2012-04-07 11:47:18 +02:00
smsc ethernet: Use eth_random_addr 2012-07-16 22:38:27 -07:00
stmicro net:stmmac: convert driver to use devm_request_and_ioremap. 2012-08-31 16:11:37 -04:00
sun niu: Change niu_rbr_fill() to use unlikely() to check niu_rbr_add_page() return value 2012-07-22 23:31:07 -07:00
tehuti drivers/net/ethernet: Fix (nearly-)kernel-doc comments for various functions 2012-07-10 23:13:46 -07:00
ti Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2012-09-15 11:43:53 -04:00
tile tilegx net: use eth_hw_addr_random(), not eth_random_addr() 2012-07-18 15:07:45 -04:00
toshiba drivers/net/ethernet: Fix (nearly-)kernel-doc comments for various functions 2012-07-10 23:13:46 -07:00
tundra drivers/net/ethernet/tundra/tsi108_eth.c: delete double assignment 2012-08-30 13:08:37 -04:00
via ethernet: Remove casts to same type 2012-06-06 09:31:33 -07:00
wiznet w5300: using eth_hw_addr_random() for random MAC and set device flag 2012-08-24 13:30:27 -04:00
xilinx ethernet: Use eth_random_addr 2012-07-16 22:38:27 -07:00
xircom
xscale ixp4xx_eth: fix ptp_ixp46x build failure 2012-08-06 13:30:01 -07:00
dnet.c dnet: Support the get_ts_info ethtool method. 2012-04-04 05:28:46 -04:00
dnet.h
ethoc.c ethernet: Use eth_random_addr 2012-07-16 22:38:27 -07:00
fealnx.c fealnx: Remove unused local label 'out' in netdev_open(). 2012-04-07 09:02:32 -04:00
jme.c jme: netpoll support 2012-07-18 09:40:54 -07:00
jme.h
Kconfig Ethernet driver for the WIZnet W5300 chip 2012-04-05 01:43:02 -04:00
korina.c
lantiq_etop.c ethernet: Use eth_random_addr 2012-07-16 22:38:27 -07:00
Makefile Ethernet driver for the WIZnet W5300 chip 2012-04-05 01:43:02 -04:00
mipsnet.c
netx-eth.c
s6gmac.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2012-05-22 19:22:50 -07:00