linux/drivers/net/bonding
dingtianhong eb9fa4b019 bonding: rebuild the lock use for bond_activebackup_arp_mon()
The bond_activebackup_arp_mon() use the bond lock for read to
protect the slave list, it is no effect, and the RTNL is only
called for bond_ab_arp_commit() and peer notify, for the performance
better, use RCU to replace with the bond lock, to the bond slave
list need to called in RCU, add a new bond_first_slave_rcu()
to get the first slave in RCU protection.

In bond_ab_arp_probe(), the bond->current_arp_slave may changd
if bond release slave, just like:

        bond_ab_arp_probe()                     bond_release()
        cpu 0                                   cpu 1
        ...
        if (bond->current_arp_slave...)         ...
        ...                             bond->current_arp_slave = NULl
        bond->current_arp_slave->dev->name      ...

So the current_arp_slave need to dereference in the section.

Suggested-by: Nikolay Aleksandrov <nikolay@redhat.com>
Suggested-by: Jay Vosburgh <fubar@us.ibm.com>
Suggested-by: Veaceslav Falico <vfalico@redhat.com>
Signed-off-by: Ding Tianhong <dingtianhong@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2013-12-14 01:58:02 -05:00
..
bond_3ad.c Revert "Merge branch 'bonding_monitor_locking'" 2013-10-28 00:11:22 -04:00
bond_3ad.h bonding: fix multiple 3ad mode sysfs race conditions 2013-05-19 23:25:49 -07:00
bond_alb.c bonding: rebuild the lock use for bond_alb_monitor() 2013-12-14 01:58:01 -05:00
bond_alb.h drivers/net/*: Fix FSF address in file headers 2013-12-06 12:37:55 -05:00
bond_debugfs.c bonding: delete migrated IP addresses from the rlb hash table 2012-11-30 12:07:27 -05:00
bond_main.c bonding: rebuild the lock use for bond_activebackup_arp_mon() 2013-12-14 01:58:02 -05:00
bond_netlink.c bonding: add arp_all_targets netlink support 2013-12-14 01:07:32 -05:00
bond_options.c bonding: add arp_all_targets netlink support 2013-12-14 01:07:32 -05:00
bond_procfs.c bonding: don't use bond_next_slave() in bond_info_seq_next() 2013-09-28 15:28:06 -07:00
bond_sysfs.c bonding: add arp_all_targets netlink support 2013-12-14 01:07:32 -05:00
bonding.h bonding: create bond_first_slave_rcu() 2013-12-14 01:58:02 -05:00
Makefile bonding: move mode setting into separate function 2013-10-19 18:58:45 -04:00