linux-sg2042/drivers/net/ethernet/stmicro/stmmac
Thor Thayer 8137b6ef0c net: stmmac: Fix RX packet size > 8191
Ping problems with packets > 8191 as shown:

PING 192.168.1.99 (192.168.1.99) 8150(8178) bytes of data.
8158 bytes from 192.168.1.99: icmp_seq=1 ttl=64 time=0.669 ms
wrong data byte 8144 should be 0xd0 but was 0x0
16    10 11 12 13 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f
      20 21 22 23 24 25 26 27 28 29 2a 2b 2c 2d 2e 2f
%< ---------------snip--------------------------------------
8112  b0 b1 b2 b3 b4 b5 b6 b7 b8 b9 ba bb bc bd be bf
      c0 c1 c2 c3 c4 c5 c6 c7 c8 c9 ca cb cc cd ce cf
8144  0 0 0 0 d0 d1
      ^^^^^^^
Notice the 4 bytes of 0 before the expected byte of d0.

Databook notes that the RX buffer must be a multiple of 4/8/16
bytes [1].

Update the DMA Buffer size define to 8188 instead of 8192. Remove
the -1 from the RX buffer size allocations and use the new
DMA Buffer size directly.

[1] Synopsys DesignWare Cores Ethernet MAC Universal v3.70a
    [section 8.4.2 - Table 8-24]

Tested on SoCFPGA Stratix10 with ping sweep from 100 to 8300 byte packets.

Fixes: 286a837217 ("stmmac: add CHAINED descriptor mode support (V4)")
Suggested-by: Jose Abreu <jose.abreu@synopsys.com>
Signed-off-by: Thor Thayer <thor.thayer@linux.intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2018-11-08 19:47:44 -08:00
..
Kconfig net: stmmac: build the dwmac-socfpga platform driver for Stratix10 2018-08-29 19:39:53 -07:00
Makefile net: stmmac: Add descriptor related callbacks for XGMAC2 2018-08-09 11:16:28 -07:00
altr_tse_pcs.c net: ethernet: stmmac: Convert timers to use timer_setup() 2017-10-18 12:39:37 +01:00
altr_tse_pcs.h
chain_mode.c net: stmmac: Switch stmmac_mode_ops to generic HW Interface Helpers 2018-04-16 18:50:03 -04:00
common.h net: stmmac: Fix RX packet size > 8191 2018-11-08 19:47:44 -08:00
descs.h net: stmmac: remove freesoftware address 2017-02-08 15:11:23 -05:00
descs_com.h net: stmmac: Fix RX packet size > 8191 2018-11-08 19:47:44 -08:00
dwmac-anarion.c net: stmmac: Add Adaptrum Anarion GMAC glue layer 2017-08-06 21:31:32 -07:00
dwmac-dwc-qos-eth.c net: stmmac: dwc-qos-eth: Fix typo in DT bindings parsing 2017-10-27 23:23:19 +09:00
dwmac-generic.c net: stmmac: Add the bindings parsing for XGMAC2 2018-08-09 11:16:28 -07:00
dwmac-ipq806x.c net: ethernet: stmmac: Clean up dead code 2017-10-08 21:19:07 -07:00
dwmac-lpc18xx.c
dwmac-meson.c
dwmac-meson8b.c net: stmmac: dwmac-meson8b: Fix an error handling path in 'meson8b_dwmac_probe()' 2018-06-12 15:36:14 -07:00
dwmac-oxnas.c net: stmmac: dwmac-oxnas: use generic pm implementation 2017-01-03 09:33:00 -05:00
dwmac-rk.c net: ethernet: stmmac: dwmac-rk: Add GMAC support for px30 2018-06-29 22:19:05 +09:00
dwmac-socfpga.c net: stmmac: socfpga: add additional ocp reset line for Stratix10 2018-06-20 14:34:26 +09:00
dwmac-sti.c
dwmac-stm32.c net: ethernet: stmmac: add adaptation for stm32mp157c. 2018-05-28 23:08:29 -04:00
dwmac-sun8i.c net: stmmac: dwmac-sun8i: fix OF child-node lookup 2018-10-23 13:28:52 -05:00
dwmac-sunxi.c
dwmac4.h net: stmmac: Add Flexible PPS support 2018-06-04 10:13:16 -04:00
dwmac4_core.c net: stmmac: Add Flexible PPS support 2018-06-04 10:13:16 -04:00
dwmac4_descs.c net: stmmac: Let descriptor code get skbuff address 2018-05-18 11:00:16 -04:00
dwmac4_descs.h
dwmac4_dma.c Merge ra.kernel.org:/pub/scm/linux/kernel/git/davem/net 2018-07-03 10:29:26 +09:00
dwmac4_dma.h net: stmmac: Set DMA buffer size in HW 2018-06-28 22:24:25 +09:00
dwmac4_lib.c net: stmmac: prepare rx/tx set tail function for multiple queues 2017-03-15 14:44:32 -07:00
dwmac5.c net: stmmac: Add Flexible PPS support 2018-06-04 10:13:16 -04:00
dwmac5.h net: stmmac: Add Flexible PPS support 2018-06-04 10:13:16 -04:00
dwmac100.h net: stmmac: remove freesoftware address 2017-02-08 15:11:23 -05:00
dwmac100_core.c net: stmmac: Implement logic to automatically select HW Interface 2018-04-23 12:03:50 -04:00
dwmac100_dma.c net: stmmac: Uniformize the use of dma_init_* callbacks 2018-05-18 11:00:15 -04:00
dwmac1000.h net: stmmac: Implement logic to automatically select HW Interface 2018-04-23 12:03:50 -04:00
dwmac1000_core.c net: stmmac: Implement logic to automatically select HW Interface 2018-04-23 12:03:50 -04:00
dwmac1000_dma.c net: stmmac: Uniformize the use of dma_init_* callbacks 2018-05-18 11:00:15 -04:00
dwmac_dma.h net: stmmac: Adjust dump offset of DMA registers for ethtool 2017-07-24 16:19:10 -07:00
dwmac_lib.c net: stmmac: dwmac_lib: fix interchanged sleep/timeout values in DMA reset function 2017-10-13 10:19:52 -07:00
dwxgmac2.h net: stmmac: Add CBS support in XGMAC2 2018-09-01 17:40:22 -07:00
dwxgmac2_core.c net: stmmac: Add CBS support in XGMAC2 2018-09-01 17:40:22 -07:00
dwxgmac2_descs.c net: stmmac: Add descriptor related callbacks for XGMAC2 2018-08-09 11:16:28 -07:00
dwxgmac2_dma.c net: stmmac: Add CBS support in XGMAC2 2018-09-01 17:40:22 -07:00
enh_desc.c net: stmmac: Fix RX packet size > 8191 2018-11-08 19:47:44 -08:00
hwif.c net: stmmac: Enable TC Ops for GMAC >= 4 2018-09-08 10:24:30 -07:00
hwif.h net: stmmac: Add descriptor related callbacks for XGMAC2 2018-08-09 11:16:28 -07:00
mmc.h net: stmmac: remove freesoftware address 2017-02-08 15:11:23 -05:00
mmc_core.c net: stmmac: remove freesoftware address 2017-02-08 15:11:23 -05:00
norm_desc.c net: stmmac: Let descriptor code get skbuff address 2018-05-18 11:00:16 -04:00
ring_mode.c net: stmmac: Fix RX packet size > 8191 2018-11-08 19:47:44 -08:00
stmmac.h net: stmmac: Rework coalesce timer and fix multi-queue races 2018-09-18 19:48:08 -07:00
stmmac_ethtool.c net: stmmac: Use mutex instead of spinlock 2018-05-28 22:54:15 -04:00
stmmac_hwtstamp.c net: stmmac: Switch stmmac_hwtimestamp to generic HW Interface Helpers 2018-04-16 18:49:55 -04:00
stmmac_main.c Merge ra.kernel.org:/pub/scm/linux/kernel/git/davem/net 2018-09-25 10:35:29 -07:00
stmmac_mdio.c net: stmmac: Fix stmmac_mdio_reset() when building stmmac as modules 2018-10-31 18:35:58 -07:00
stmmac_pci.c net: stmmac: mark PM functions as __maybe_unused 2018-08-13 20:45:49 -07:00
stmmac_pcs.h
stmmac_platform.c stmmac: fix valid numbers of unicast filter entries 2018-09-16 15:23:48 -07:00
stmmac_platform.h
stmmac_ptp.c net: stmmac: Add PTP support for XGMAC2 2018-08-09 11:16:28 -07:00
stmmac_ptp.h net: stmmac: Add PTP support for XGMAC2 2018-08-09 11:16:28 -07:00
stmmac_tc.c net_sched: remove list_head from tc_action 2018-08-21 12:45:44 -07:00