Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Documentation: networking: update stmmac

Update stmmac driver documentation according to new GMAC 4.x family.

Signed-off-by: Alexandre TORGUE <alexandre.torgue@st.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Alexandre TORGUE and committed by
David S. Miller
0b7a43d3 f748be53

+38 -6
+38 -6
Documentation/networking/stmmac.txt
··· 1 1 STMicroelectronics 10/100/1000 Synopsys Ethernet driver 2 2 3 - Copyright (C) 2007-2014 STMicroelectronics Ltd 3 + Copyright (C) 2007-2015 STMicroelectronics Ltd 4 4 Author: Giuseppe Cavallaro <peppe.cavallaro@st.com> 5 5 6 6 This is the driver for the MAC 10/100/1000 on-chip Ethernet controllers ··· 138 138 int (*init)(struct platform_device *pdev, void *priv); 139 139 void (*exit)(struct platform_device *pdev, void *priv); 140 140 void *bsp_priv; 141 + int has_gmac4; 142 + bool tso_en; 141 143 }; 142 144 143 145 Where: ··· 183 181 registers. init/exit callbacks should not use or modify 184 182 platform data. 185 183 o bsp_priv: another private pointer. 184 + o has_gmac4: uses GMAC4 core. 185 + o tso_en: Enables TSO (TCP Segmentation Offload) feature. 186 186 187 187 For MDIO bus The we have: 188 188 ··· 282 278 o stmmac_ethtool.c: to implement the ethtool support; 283 279 o stmmac.h: private driver structure; 284 280 o common.h: common definitions and VFTs; 281 + o mmc_core.c/mmc.h: Management MAC Counters; 282 + o stmmac_hwtstamp.c: HW timestamp support for PTP; 283 + o stmmac_ptp.c: PTP 1588 clock; 284 + o dwmac-<XXX>.c: these are for the platform glue-logic file; e.g. dwmac-sti.c 285 + for STMicroelectronics SoCs. 286 + 287 + - GMAC 3.x 285 288 o descs.h: descriptor structure definitions; 286 289 o dwmac1000_core.c: dwmac GiGa core functions; 287 290 o dwmac1000_dma.c: dma functions for the GMAC chip; ··· 300 289 o enh_desc.c: functions for handling enhanced descriptors; 301 290 o norm_desc.c: functions for handling normal descriptors; 302 291 o chain_mode.c/ring_mode.c:: functions to manage RING/CHAINED modes; 303 - o mmc_core.c/mmc.h: Management MAC Counters; 304 - o stmmac_hwtstamp.c: HW timestamp support for PTP; 305 - o stmmac_ptp.c: PTP 1588 clock; 306 - o dwmac-<XXX>.c: these are for the platform glue-logic file; e.g. dwmac-sti.c 307 - for STMicroelectronics SoCs. 292 + 293 + - GMAC4.x generation 294 + o dwmac4_core.c: dwmac GMAC4.x core functions; 295 + o dwmac4_desc.c: functions for handling GMAC4.x descriptors; 296 + o dwmac4_descs.h: descriptor definitions; 297 + o dwmac4_dma.c: dma functions for the GMAC4.x chip; 298 + o dwmac4_dma.h: dma definitions for the GMAC4.x chip; 299 + o dwmac4.h: core definitions for the GMAC4.x chip; 300 + o dwmac4_lib.c: generic GMAC4.x functions; 301 + 302 + 4.12) TSO support (GMAC4.x) 303 + 304 + TSO (Tcp Segmentation Offload) feature is supported by GMAC 4.x chip family. 305 + When a packet is sent through TCP protocol, the TCP stack ensures that 306 + the SKB provided to the low level driver (stmmac in our case) matches with 307 + the maximum frame len (IP header + TCP header + payload <= 1500 bytes (for 308 + MTU set to 1500)). It means that if an application using TCP want to send a 309 + packet which will have a length (after adding headers) > 1514 the packet 310 + will be split in several TCP packets: The data payload is split and headers 311 + (TCP/IP ..) are added. It is done by software. 312 + 313 + When TSO is enabled, the TCP stack doesn't care about the maximum frame 314 + length and provide SKB packet to stmmac as it is. The GMAC IP will have to 315 + perform the segmentation by it self to match with maximum frame length. 316 + 317 + This feature can be enabled in device tree through "snps,tso" entry. 308 318 309 319 5) Debug Information 310 320