Commit dcd85bd8 authored by Leonardo Lai's avatar Leonardo Lai

limit max rx pkt size for NICs that don't support full Jumbo size

parent e0a5463d
......@@ -105,10 +105,14 @@ static int init_mbuf_pools(void)
/* Initialize a DPDK port */
static int init_port(uint16_t port_num)
{
struct rte_eth_dev_info dev_info;
rte_eth_dev_info_get(port_num, &dev_info);
const struct rte_eth_conf port_conf = {
.rxmode = {
.mq_mode = ETH_MQ_RX_RSS,
.max_rx_pkt_len = JUMBO_FRAME_MAX_SIZE,
.max_rx_pkt_len = RTE_MIN(JUMBO_FRAME_MAX_SIZE, dev_info.max_rx_pktlen),
.split_hdr_size = 0,
.offloads = (DEV_RX_OFFLOAD_CHECKSUM |
DEV_RX_OFFLOAD_SCATTER |
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment