mtcp-stack / mtcp

mTCP: A Highly Scalable User-level TCP Stack for Multicore Systems
Other
1.98k stars 436 forks source link

nic flow control is forcely disabled by mtcp #162

Closed simpx closed 6 years ago

simpx commented 6 years ago

https://github.com/eunyoung14/mtcp/blob/master/mtcp/src/dpdk_module.c#L715

I review the commit which add this code, but I don't know why should mTCP disabled flow control?

simpx commented 6 years ago

and, why we need rte_eth_promiscuous_enable?

ajamshed commented 6 years ago

simpx,

Please see this message board: https://community.hpe.com/t5/Switches-Hubs-and-Modems/When-to-use-Flow-Control/td-p/4337588. Although the content focuses on switches, the same logic can also be applied to TCP endpoints. Flow control in TCP endpoints can easily be handled in the transport layer. You can re-enable NIC flow control if you want, but my intention is to squeeze more efficiency from disabling this feature.

Enabling promiscuous mode was added as an after-thought (and was related to performance metrics). It's purpose was to show how many packets-per-second can the link layer handle (in the best case) irrespective of the labelled destination MAC address.

simpx commented 6 years ago

@ajamshed thx! 👍

I run mTCP and rdma in the same node, rdma rely on NIC flow control to ensure a lossless ethernet

so I re-enable this feature is my case

ajamshed commented 6 years ago

I will remove promiscuous mode in my next commit. Enabling promiscuous mode makes more sense for projects like the mOS networking stack.