]> git.baikalelectronics.ru Git - kernel.git/commit
bonding: fix locking during alb failover and slave removal
authorJay Vosburgh <fubar@us.ibm.com>
Fri, 18 Jan 2008 00:24:59 +0000 (16:24 -0800)
committerJeff Garzik <jeff@garzik.org>
Fri, 18 Jan 2008 19:38:38 +0000 (14:38 -0500)
commit62e3d3b4f3c8866ed0ac82031c757fa48fee0f00
tree83c43c448b7f18541dbe70ca4ff80138f8e695d4
parent942135515e6e0d33bc32f35f48eb008cdadbb69b
bonding: fix locking during alb failover and slave removal

alb_fasten_mac_swap (actually rlb_teach_disabled_mac_on_primary)
requries RTNL and no other locks.  This could cause dev_set_promiscuity
and/or dev_set_mac_address to be called with improper locking.

Changed callers to hold only RTNL during calls to alb_fasten_mac_swap
or functions calling it.  Updated header comments in affected functions to
reflect proper reality of locking requirements.

Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
drivers/net/bonding/bond_alb.c
drivers/net/bonding/bond_main.c