[dpdk-dev] [PATCH] net/mlx4: add support for multicast address list interface

Shahaf Shuler shahafs at mellanox.com
Mon Apr 29 10:54:36 CEST 2019


Thursday, April 18, 2019 4:11 PM, Adrien Mazarguil:
> Subject: [PATCH] net/mlx4: add support for multicast address list interface
> 
> Since this driver does not distinguish unicast/multicast addresses,
> applications could always rely on the standard MAC add/remove/set
> interface to configure both types.
> 
> As a result, the multicast address list interface never got implemented
> (rte_eth_dev_set_mc_addr_list()) however PMD-agnostic applications still
> rely on it for compatibility reasons; a wrapper is therefore required.
> 
> Signed-off-by: Adrien Mazarguil <adrien.mazarguil at 6wind.com>

Applied to next-net-mlx with a small change (see below). 

> ---
>  drivers/net/mlx4/mlx4.c        |  1 +
>  drivers/net/mlx4/mlx4.h        |  3 ++
>  drivers/net/mlx4/mlx4_ethdev.c | 61

[...]

> @@ -488,6 +488,63 @@ mlx4_mac_addr_add(struct rte_eth_dev *dev,
> struct ether_addr *mac_addr,  }
> 
>  /**
> + * DPDK callback to configure multicast addresses.
> + *
> + * @param dev
> + *   Pointer to Ethernet device structure.
> + * @param list
> + *   List of MAC addresses to register.
> + * @param num
> + *   Number of entries in list.
> + *
> + * @return
> + *   0 on success, negative errno value otherwise and rte_errno is set.
> + */
> +int
> +mlx4_set_mc_addr_list(struct rte_eth_dev *dev, struct ether_addr *list,
> +		      uint32_t num)
> +{
> +	struct priv *priv = dev->data->dev_private;

I have modified it to struct mlx4_priv. please shout if you disagree.



More information about the dev mailing list