summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/broadcom/bcmsysport.h
diff options
context:
space:
mode:
authorFlorian Fainelli <f.fainelli@gmail.com>2014-05-15 06:32:14 +0400
committerDavid S. Miller <davem@davemloft.net>2014-05-16 00:48:38 +0400
commitdab531b4305bc2852ce6f934dc283464d46871a5 (patch)
tree9fccae4546ce7df0646a101c2eda002152ffe229 /drivers/net/ethernet/broadcom/bcmsysport.h
parentd5e32cc7c997d1d4f18031f5ff88512bd65118f7 (diff)
downloadlinux-dab531b4305bc2852ce6f934dc283464d46871a5.tar.xz
net: systemport: pad packets to a minimum of 68 bytes
Packets need to be at least 64 bytes to enter the switch port logic, including the FCS, otherwise they will be discarded as RUNT packets. With packets having Broadcom tags, the 4-bytes tag is first stripped off the packet, and the packet length is then checked, so we need to make sure that the packet length with FCS is at least 64 bytes. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/broadcom/bcmsysport.h')
-rw-r--r--drivers/net/ethernet/broadcom/bcmsysport.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/ethernet/broadcom/bcmsysport.h b/drivers/net/ethernet/broadcom/bcmsysport.h
index a0441e7c83cd..abdeb62616df 100644
--- a/drivers/net/ethernet/broadcom/bcmsysport.h
+++ b/drivers/net/ethernet/broadcom/bcmsysport.h
@@ -29,11 +29,11 @@
/* Default RX buffer allocation size */
#define RX_BUF_LENGTH 2048
-/* Body(1500) + EH_SIZE(14) + VLANTAG(4) + BRCMTAG(6) + FCS(4) = 1528.
+/* Body(1500) + EH_SIZE(14) + VLANTAG(4) + BRCMTAG(4) + FCS(4) = 1526.
* 1536 is multiple of 256 bytes
*/
-#define ENET_BRCM_TAG_LEN 6
-#define ENET_PAD 8
+#define ENET_BRCM_TAG_LEN 4
+#define ENET_PAD 10
#define UMAC_MAX_MTU_SIZE (ETH_DATA_LEN + ETH_HLEN + VLAN_HLEN + \
ENET_BRCM_TAG_LEN + ETH_FCS_LEN + ENET_PAD)