From c27ebf58517536c0006813007680b24db17def47 Mon Sep 17 00:00:00 2001 From: Suresh Reddy Date: Wed, 7 Sep 2016 19:57:53 +0530 Subject: be2net: Fix mac address collision in some configurations If the device mac address is updated using ndo_set_mac_address(), while the same mac address is already programmed, the driver does not detect this condition if its netdev->dev_addr has been changed. The driver tries to add the same mac address resulting in mac address collision error. This has been observed in bonding mode-5 configuration. To fix this, store the mac address configured in HW in the adapter structure. Use this to compare against the new address being updated to avoid collision. Signed-off-by: Suresh Reddy Signed-off-by: Sathya Perla Signed-off-by: Sriharsha Basavapatna Signed-off-by: David S. Miller --- drivers/net/ethernet/emulex/benet/be.h | 1 + 1 file changed, 1 insertion(+) (limited to 'drivers/net/ethernet/emulex/benet/be.h') diff --git a/drivers/net/ethernet/emulex/benet/be.h b/drivers/net/ethernet/emulex/benet/be.h index eecf24e92fd3..30a26aa39a2b 100644 --- a/drivers/net/ethernet/emulex/benet/be.h +++ b/drivers/net/ethernet/emulex/benet/be.h @@ -693,6 +693,7 @@ struct be_adapter { u32 fat_dump_len; u16 serial_num[CNTL_SERIAL_NUM_WORDS]; u8 phy_state; /* state of sfp optics (functional, faulted, etc.,) */ + u8 dev_mac[ETH_ALEN]; u32 priv_flags; /* ethtool get/set_priv_flags() */ struct be_error_recovery error_recovery; }; -- cgit v1.2.3-55-g7522