The member "max_rx_pkt_len" of "port_conf" is only used if jumbo_frame enabled, so it can be initialized with value '0'.
Signed-off-by: Binbin Xu <xu.binb...@zte.com.cn> --- lib/netdev-dpdk.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/lib/netdev-dpdk.c b/lib/netdev-dpdk.c index 39bf930..c4a0cc0 100644 --- a/lib/netdev-dpdk.c +++ b/lib/netdev-dpdk.c @@ -154,6 +154,7 @@ static char *vhost_sock_dir = NULL; /* Location of vhost-user sockets */ static const struct rte_eth_conf port_conf = { .rxmode = { .mq_mode = ETH_MQ_RX_RSS, + .max_rx_pkt_len = 0, .split_hdr_size = 0, .header_split = 0, /* Header Split disabled */ .hw_ip_checksum = 0, /* IP checksum offload disabled */ @@ -648,9 +649,6 @@ dpdk_eth_dev_queue_setup(struct netdev_dpdk *dev, int n_rxq, int n_txq) if (dev->mtu > ETHER_MTU) { conf.rxmode.jumbo_frame = 1; conf.rxmode.max_rx_pkt_len = dev->max_packet_len; - } else { - conf.rxmode.jumbo_frame = 0; - conf.rxmode.max_rx_pkt_len = 0; } /* A device may report more queues than it makes available (this has * been observed for Intel xl710, which reserves some of them for -- 2.9.3 _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev