Testpmd parameter --max-pkt-len does not update MTU of ports bound to a kernel driver
https://bugs.dpdk.org/show_bug.cgi?id=1470
Bug ID: 1470
Summary: Testpmd parameter --max-pkt-len does not update MTU of
ports bound to a kernel driver
Product: DPDK
Version: unspecified
Hardware: All
OS: All
Status: UNCONFIRMED
Severity: normal
Priority: Normal
Component: testpmd
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: ---
If testpmd is started with the parameter --max-pkt-len, the expected behavior would be that the MTU of the port is updated to what that value is set to. In the case of devices that use a kernel driver while running testpmd (like mlx5_core for example), show port info will show that the MTU is the value that you set --max-pkt-len to. However, if you look at the network interface for the same port using the ip a command, it will report the unchanged MTU of the port. Additionally, all packets that are higher than the MTU reported by the kernel network interface will be dropped, regardless of whether or not the value given to --max-pkt-len is high enough to handle them.
If, however, you run the command port config all max-pkt-len 9000, the mtu of the kernel network interface will be updated to 8982 and the mtu listed by show port info 0 will match. The documentation listed here [1] says that this command "is equivalent to the --max-pkt-len command-line option." but the two have different outcomes. Also, as a note, if you set the mtu using port config mtu 0 9000, the mtu of the kernel network interface and the MTU displayed by show port info 0 will match and both be 9000.
For example, starting testpmd in interactive mode on a NIC running on the mlx5_core driver with the parameter --max-pkt-len=9000 and then running show port info 0 will show "MTU: 8982". However, on the same host, while testpmd is running, if I run ip a the MTU of the interface for this port is set to 1500 and any packet larger than 1500 bytes will get dropped. If you then run port stop all followed by port config all max-pkt-len 9000, you can run show port info 0 and you will see the same mtu value, 8982, but then if you run ip a you will see that the kernel network interface also has this updated MTU value. Only then, after starting the ports again, can you send packets larger than 1500 bytes.
The MTU listed in show port info seems to be more accurate when bound to vfio-pci instead, however.
[1]
https://doc.dpdk.org/guides/testpmd_app_ug/testpmd_funcs.html#port-config-max-pkt-len
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
https://bugs.dpdk.org/show_bug.cgi?id=1470
Bug 1470 depends on bug 1483, which changed state.
Bug 1483 Summary: mlx5 PMD does not apply MTU from rte_eth_conf.rxmode.mtu on rte_eth_dev_configure()
https://bugs.dpdk.org/show_bug.cgi?id=1483
What |Removed |Added
----------------------------------------------------------------------------
Status|IN_PROGRESS |RESOLVED
Resolution|--- |FIXEDSignature · 2 lines
You are receiving this mail because: You are the assignee for the bug.
http://bugs.dpdk.org/show_bug.cgi?id=1470
[email protected] ([email protected]) changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |RESOLVED
CC| |[email protected]
Resolution|--- |FIXED--- Comment #4 from [email protected] ([email protected]) --- resolved as mentioned above
Signature · 2 lines
You are receiving this mail because: You are the assignee for the bug.