Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

#5 setting master interfaces MAC address doesn't work (2.4.xx)

open
nobody
None
5
2004-03-15
2004-03-15
Kari Hautio
No

Master interfaces MAC address doesn't get set correctly
when interfaces are attached.

Following simple patch solves this issue

The comment following the modification is obviosly
wrong also.

-- Kari
<<clip>>
diff -urN -X exclude.txt
linux-2.4.24/drivers/net/bonding/bond_main.c
newKernel/drivers/net/bonding/bond_main.c
--- linux-2.4.24/drivers/net/bonding/bond_main.c
2003-11-28 20:26:20.000000000 +0200
+++ newKernel/drivers/net/bonding/bond_main.c
2004-03-05 17:55:22.000000000 +0200
@@ -1431,7 +1432,7 @@
*/
memcpy(new_slave->perm_hwaddr, slave_dev->dev_addr,
ETH_ALEN);

- if (bond->slave_cnt > 0) {
+ if (bond->slave_cnt > 0 || master_dev->dev_addr !=
slave_dev->dev_addr ) {
/* set slave to master's mac address
* The application already set the master's
* mac address to that of the first slave
<<clap>>

Discussion