diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-11-10 14:23:56 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-11-10 14:23:56 -0800 |
commit | 1da63a2131b0185f64a4c623a0e0b030479185fe (patch) | |
tree | e859fc05e2904400bf8b0b23f419532c874e43a9 /drivers/net/bonding/bond_sysfs.c | |
parent | 3902beb48d369d5e19f66acc2f857865ddc9b3bf (diff) | |
parent | a6baf3af89a266a3d745117de570788b956396e7 (diff) |
Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6
* 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6: (40 commits)
r8169: prevent bit sign expansion error in mdio_write
r8169: revert 7da97ec96a0934319c7fbedd3d38baf533e20640 (bis repetita)
sky2: new pci id's
ax88796: add superh to kconfig dependencies
qla3xxx: bugfix: Fix bad logical operation in link state machine.
qla3xxx: bugfix: Move link state machine into a worker thread
pasemi_mac: Fix CRC checks
pasemi_mac: Don't set replace-source-address descriptor bits
bonding: don't validate address at device open
bonding: fix rtnl locking merge error
sky2: netpoll on port 0 only
b43: Fix kconfig dependencies for rfkill and leds
b43legacy: Fix sparse warning
b43: properly request pcmcia IRQ
b43legacy: fix shared IRQ race condition
b43: fix shared IRQ race condition
b43legacy: add me as maintainer and fix URLs
b43legacy: fix possible buffer overrun in debugfs
b43: Rewrite and fix rfkill init
b43: debugfs SHM read buffer overrun fix
...
Diffstat (limited to 'drivers/net/bonding/bond_sysfs.c')
-rw-r--r-- | drivers/net/bonding/bond_sysfs.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/bonding/bond_sysfs.c b/drivers/net/bonding/bond_sysfs.c index 7a06ade85b0..b29330d8e30 100644 --- a/drivers/net/bonding/bond_sysfs.c +++ b/drivers/net/bonding/bond_sysfs.c @@ -1193,8 +1193,6 @@ static ssize_t bonding_show_active_slave(struct device *d, struct bonding *bond = to_bond(d); int count; - rtnl_lock(); - read_lock(&bond->curr_slave_lock); curr = bond->curr_active_slave; read_unlock(&bond->curr_slave_lock); @@ -1216,7 +1214,9 @@ static ssize_t bonding_store_active_slave(struct device *d, struct slave *new_active = NULL; struct bonding *bond = to_bond(d); + rtnl_lock(); write_lock_bh(&bond->lock); + if (!USES_PRIMARY(bond->params.mode)) { printk(KERN_INFO DRV_NAME ": %s: Unable to change active slave; %s is in mode %d\n", |