Commit 3b96c858 authored by Jay Vosburgh's avatar Jay Vosburgh Committed by Jeff Garzik

bonding: release slaves when master removed via sysfs

	Add a call to bond_release_all in the bonding netdev event
handler for the master.  This releases the slaves for the case of, e.g.,
"echo -bond0 > /sys/class/net/bonding_masters", which otherwise will spin
forever waiting for references to be released.
Signed-off-by: default avatarJay Vosburgh <fubar@us.ibm.com>
Signed-off-by: default avatarJeff Garzik <jeff@garzik.org>
parent 2543331d
...@@ -3401,9 +3401,7 @@ static int bond_master_netdev_event(unsigned long event, struct net_device *bond ...@@ -3401,9 +3401,7 @@ static int bond_master_netdev_event(unsigned long event, struct net_device *bond
case NETDEV_CHANGENAME: case NETDEV_CHANGENAME:
return bond_event_changename(event_bond); return bond_event_changename(event_bond);
case NETDEV_UNREGISTER: case NETDEV_UNREGISTER:
/* bond_release_all(event_bond->dev);
* TODO: remove a bond from the list?
*/
break; break;
default: default:
break; break;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment