[dpdk-dev] [PATCH] net/bonding: fix bond 8023ad mode enable using wrong index
Kyle Larose
klarose at sandvine.com
Thu Nov 23 23:57:12 CET 2017
Hello,
> -----Original Message-----
> From: dev [mailto:dev-bounces at dpdk.org] On Behalf Of Lilijun (Jerry)
> Sent: Monday, November 20, 2017 2:16 AM
> To: dev at dpdk.org; tomaszx.kulasek at intel.com
> Cc: Zhang, Jerry; Wanghanlin
> Subject: [dpdk-dev] [PATCH] net/bonding: fix bond 8023ad mode enable
> using wrong index
>
> Hi all,
>
> In the function bond_mode_8023ad_enable(), the var i is to used to
> as the second parameter to pass the slave dev's dpdk port id to the
> function bond_mode_8023ad_activate_slave().
> I think this variable is only a index for array internals-
> >active_slaves. So its need to be fixed and change i to internals-
> >active_slaves[i].
>
>
> [Patch] net/bonding: fix bond 8023ad mode enable using wrong index.
> Signed-off-by: Lilijun <jerry.lilijun at huawei.com>
>
> diff --git a/drivers/net/bonding/rte_eth_bond_8023ad.c
> b/drivers/net/bonding/rte_eth_bond_8023ad.c
> index a2313b3..20a08dc 100644
> --- a/drivers/net/bonding/rte_eth_bond_8023ad.c
> +++ b/drivers/net/bonding/rte_eth_bond_8023ad.c
> @@ -1159,7 +1159,7 @@
> uint8_t i;
>
> for (i = 0; i < internals->active_slave_count; i++)
> - bond_mode_8023ad_activate_slave(bond_dev, i);
> + bond_mode_8023ad_activate_slave(bond_dev, internals-
> >active_slaves[i]);
>
> return 0;
> }
>
I have tested this, and it alleviates some of the issues I was reporting earlier with link aggregator selection.
Tested-by: Kyle Larose <klarose at sandvine.com>
Thanks,
Kyle
More information about the dev
mailing list