[PATCH v3] netdev-dpdk: add control plane protection support
Robin Jarry
rjarry at redhat.com
Mon Nov 14 13:46:18 CET 2022
Hi Kevin,
Kevin Traynor, Nov 11, 2022 at 19:15:
> > + reta_conf_size = (dev->reta_size / RTE_ETH_RETA_GROUP_SIZE)
> > + * sizeof(struct rte_eth_rss_reta_entry64);
>
> In dpdk_eth_dev_init, we get reta_size from driver,
>
> mlx5_ethdev.c
>
> 333├> info->reta_size = priv->reta_idx_n ?
> 334│ priv->reta_idx_n : config->ind_table_max_size;
>
> (gdb) p priv->reta_idx_n
> $5 = 1
> (gdb) p config->ind_table_max_size
> $6 = 512
>
> and store:
> dev->reta_size = info.reta_size;
>
> Now we use it,
> dev->reta_size = 1 / RTE_ETH_RETA_GROUP_SIZE (64)
> but it results in reta_conf_size = 0
>
> > + reta_conf = xmalloc(reta_conf_size);
>
> xmalloc only allocates 1 byte (void *p = malloc(size ? size : 1);)
Hmm indeed this is bad :)
Since reworking the RSS fallback I may not have re-tested with CX-5,
only with Intel NICs.
I am quite surprised of this return value. Could it be an issue with the
mlx5 dpdk driver?
Thanks for testing!
More information about the dev
mailing list