aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/stmmac/dwmac1000.h
diff options
context:
space:
mode:
authorGiuseppe CAVALLARO <peppe.cavallaro@st.com>2010-07-27 00:09:47 +0000
committerDavid S. Miller <davem@davemloft.net>2010-07-27 20:43:50 -0700
commit3eeb29972b1139f733f7269def527900729f4cc7 (patch)
tree7189feaee380e0921c65935879e65030b01d9560 /drivers/net/stmmac/dwmac1000.h
parentstmmac: fix timer setup when use dual mac Kconfig (diff)
downloadlinux-dev-3eeb29972b1139f733f7269def527900729f4cc7.tar.xz
linux-dev-3eeb29972b1139f733f7269def527900729f4cc7.zip
stmmac: fix automatic PAD/FCS stripping
For Simple Ethernet frames (802.2 and 802.3) the GMAC Core never strips pad and fcs. This means the ACS has no effect on IPv4/6 frames. The FL bits, in the RDES0, include the FCS so the driver has to remove it in SW. For 802.3 frame format with LLC or LLC-SNAP, when set the ACS bit, the HW strips both PAD and FCS. The FL bits, in the RDES0, actually represents the frame length already stripped. This patch fixes this logic within the device driver that erroneously removed 4byte from 802.3 frames already stripped corrupting the payload. Signed-off-by: Giuseppe Cavallaro <peppe.cavallaro@st.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/stmmac/dwmac1000.h')
-rw-r--r--drivers/net/stmmac/dwmac1000.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/stmmac/dwmac1000.h b/drivers/net/stmmac/dwmac1000.h
index d8d0f3553770..8b20b19971cb 100644
--- a/drivers/net/stmmac/dwmac1000.h
+++ b/drivers/net/stmmac/dwmac1000.h
@@ -93,7 +93,7 @@ enum inter_frame_gap {
#define GMAC_CONTROL_IPC 0x00000400 /* Checksum Offload */
#define GMAC_CONTROL_DR 0x00000200 /* Disable Retry */
#define GMAC_CONTROL_LUD 0x00000100 /* Link up/down */
-#define GMAC_CONTROL_ACS 0x00000080 /* Automatic Pad Stripping */
+#define GMAC_CONTROL_ACS 0x00000080 /* Automatic Pad/FCS Stripping */
#define GMAC_CONTROL_DC 0x00000010 /* Deferral Check */
#define GMAC_CONTROL_TE 0x00000008 /* Transmitter Enable */
#define GMAC_CONTROL_RE 0x00000004 /* Receiver Enable */