bonding: fix current primary port
authorBernard Iremonger <bernard.iremonger@intel.com>
Wed, 23 Mar 2016 17:30:05 +0000 (17:30 +0000)
committerThomas Monjalon <thomas.monjalon@6wind.com>
Fri, 25 Mar 2016 18:03:48 +0000 (19:03 +0100)
commite0665f9809517217c1bd1280f3ef3f387f217fe0
tree15c77f63109532b927755a7ef2418e3d808f42e2
parent9d2f7db9c0bb77eb1658d530f94488afba5fa01f
bonding: fix current primary port

The current_primary_port is initialised to an invalid value
during bonded device creation.
It must be set to a valid value later.
This fix sets it to a valid value when the first slave port
is added to the bonding device.

Fixes: 2efb58cbab6e ("bond: new link bonding library")

Signed-off-by: Bernard Iremonger <bernard.iremonger@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
drivers/net/bonding/rte_eth_bond_api.c