On 4/21/2020 8:50 AM, Kiran KN wrote: > > Change the maximum packet length to accommodate jumbo frames > > signed-off-by: Kiran KN <kira...@juniper.net> > > --- > drivers/net/af_packet/rte_eth_af_packet.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/net/af_packet/rte_eth_af_packet.c > b/drivers/net/af_packet/rte_eth_af_packet.c > index f5806bf42..7fe3a28a7 100644 > --- a/drivers/net/af_packet/rte_eth_af_packet.c > +++ b/drivers/net/af_packet/rte_eth_af_packet.c > @@ -312,7 +312,7 @@ eth_dev_info(struct rte_eth_dev *dev, struct > rte_eth_dev_info *dev_info) > > dev_info->if_index = internals->if_index; > dev_info->max_mac_addrs = 1; > - dev_info->max_rx_pktlen = (uint32_t)ETH_FRAME_LEN; > + dev_info->max_rx_pktlen = (uint32_t)RTE_ETHER_MAX_JUMBO_FRAME_LEN; > dev_info->max_rx_queues = (uint16_t)internals->nb_queues; > dev_info->max_tx_queues = (uint16_t)internals->nb_queues; > dev_info->min_rx_bufsize = 0; >
Hi Kiran, What is the intention of the patch, to be more accurate or to enable receiving packets larger than 1500 bytes? If intention is to receive large packets not sure if this change on its own enables it, a) PMD doesn't announce RX_OFFLOAD_JUMBO_FRAME, so 'rte_eth_dev_configure()' can't configure the larger than 'RTE_ETHER_MAX_LEN' anyway b) PMD '.dev_configure' dev_ops is empty, even you pass larger Rx packet length, PMD won't configure underneath interface. So I think the required change is more than this patch. To get larger packets, need to call 'rte_eth_dev_set_mtu()' to set underneath interface MTU to be able to get larger packets, which is independent from 'max_rx_pktlen'. And for to be more accurate option, isn't the real max Rx packet size limitation of the PMD is 'tp_frame_size'? And from interface point of view, is the jumbo frame length really the max, can the GRO be enabled for the interface, in that case I don't know what can be the max Rx packet length.