Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F101933732
D47066.id144761.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D47066.id144761.diff
View Options
diff --git a/sys/dev/dpaa2/dpaa2_ni.c b/sys/dev/dpaa2/dpaa2_ni.c
--- a/sys/dev/dpaa2/dpaa2_ni.c
+++ b/sys/dev/dpaa2/dpaa2_ni.c
@@ -138,8 +138,9 @@
#define DPNI_IRQ_LINK_CHANGED 1 /* Link state changed */
#define DPNI_IRQ_EP_CHANGED 2 /* DPAA2 endpoint dis/connected */
-/* Default maximum frame length. */
-#define DPAA2_ETH_MFL (ETHER_MAX_LEN - ETHER_CRC_LEN)
+/* Default maximum RX frame length w/o CRC. */
+#define DPAA2_ETH_MFL (ETHER_MAX_LEN_JUMBO + ETHER_VLAN_ENCAP_LEN - \
+ ETHER_CRC_LEN)
/* Minimally supported version of the DPNI API. */
#define DPNI_VER_MAJOR 7
@@ -2561,8 +2562,10 @@
DPNI_UNLOCK(sc);
/* Update maximum frame length. */
- error = DPAA2_CMD_NI_SET_MFL(dev, child, &cmd,
- mtu + ETHER_HDR_LEN + ETHER_VLAN_ENCAP_LEN);
+ mtu += ETHER_HDR_LEN;
+ if (if_getcapenable(ifp) & IFCAP_VLAN_MTU)
+ mtu += ETHER_VLAN_ENCAP_LEN;
+ error = DPAA2_CMD_NI_SET_MFL(dev, child, &cmd, mtu);
if (error) {
device_printf(dev, "%s: failed to update maximum frame "
"length: error=%d\n", __func__, error);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Nov 6, 4:09 PM (5 h, 41 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
13957659
Default Alt Text
D47066.id144761.diff (1 KB)
Attached To
Mode
D47066: dpaa2: fix MRU for dpni (and software vlans along)
Attached
Detach File
Event Timeline
Log In to Comment