linux/drivers/net/bonding
dingtianhong fe9d04afe9 bonding: disable arp and enable mii monitoring when bond change to no uses arp mode
Because the ARP monitoring is not support for 802.3ad, but I still
could change the mode to 802.3ad from ab mode while ARP monitoring
is running, it is incorrect.

So add a check for 802.3ad in bonding_store_mode to fix the problem,
and make a new macro BOND_NO_USES_ARP() to simplify the code.

v2: according to the Dan Williams's suggestion, bond mode is the most
    important bond option, it should override any of the other sub-options.
    So when the mode is changed, the conficting values should be cleared
    or reset, otherwise the user has to duplicate more operations to modify
    the logic. I disable the arp and enable mii monitoring when the bond mode
    is changed to AB, TB and 8023AD if the arp interval is true.

v3: according to the Nik's suggestion, the default value of miimon should need
    a name, there is several place to use it, and the bond_store_arp_interval()
    could use micro BOND_NO_USES_ARP to make the code more simpify.

Suggested-by: Dan Williams <dcbw@redhat.com>
Suggested-by: Nikolay Aleksandrov <nikolay@redhat.com>
Signed-off-by: Ding Tianhong <dingtianhong@huawei.com>
Reviewed-by: Nikolay Aleksandrov <nikolay@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2013-11-28 18:20:18 -05:00
..
Makefile bonding: move mode setting into separate function 2013-10-19 18:58:45 -04: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 Revert "Merge branch 'bonding_monitor_locking'" 2013-10-28 00:11:22 -04:00
bond_alb.h bonding: rework rlb_next_rx_slave() to use bond_for_each_slave() 2013-09-26 16:02:05 -04: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: disable arp and enable mii monitoring when bond change to no uses arp mode 2013-11-28 18:20:18 -05:00
bond_netlink.c bonding: bond_get_size() returns wrong size 2013-11-02 02:08:54 -04:00
bond_options.c bonding: disable arp and enable mii monitoring when bond change to no uses arp mode 2013-11-28 18:20:18 -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: disable arp and enable mii monitoring when bond change to no uses arp mode 2013-11-28 18:20:18 -05:00
bonding.h bonding: disable arp and enable mii monitoring when bond change to no uses arp mode 2013-11-28 18:20:18 -05:00