diff options
author | Veaceslav Falico <vfalico@redhat.com> | 2012-04-04 23:47:43 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-04-05 19:07:59 -0400 |
commit | 5a4309746cd74734daa964acb02690c22b3c8911 (patch) | |
tree | 69a985f74ca76d5524ef2854bc6e3c18bc19a25a /drivers/net/bonding | |
parent | bcf1b70ac6eb0ed8286c66e6bf37cb747cbaa04c (diff) |
bonding: properly unset current_arp_slave on slave link up
When a slave comes up, we're unsetting the current_arp_slave without
removing active flags from it, which can lead to situations where we have
more than one slave with active flags in active-backup mode.
To avoid this situation we must remove the active flags from a slave before
removing it as a current_arp_slave.
Signed-off-by: Veaceslav Falico <vfalico@redhat.com>
Signed-off-by: Jay Vosburgh <fubar@us.ibm.com>
Signed-off-by: Andy Gospodarek <andy@greyhouse.net>
Signed-off-by: Marcelo Ricardo Leitner <mleitner@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/bonding')
-rw-r--r-- | drivers/net/bonding/bond_main.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c index fc8a8d5c4dbd..62d2409bb293 100644 --- a/drivers/net/bonding/bond_main.c +++ b/drivers/net/bonding/bond_main.c | |||
@@ -3010,7 +3010,11 @@ static void bond_ab_arp_commit(struct bonding *bond, int delta_in_ticks) | |||
3010 | trans_start + delta_in_ticks)) || | 3010 | trans_start + delta_in_ticks)) || |
3011 | bond->curr_active_slave != slave) { | 3011 | bond->curr_active_slave != slave) { |
3012 | slave->link = BOND_LINK_UP; | 3012 | slave->link = BOND_LINK_UP; |
3013 | bond->current_arp_slave = NULL; | 3013 | if (bond->current_arp_slave) { |
3014 | bond_set_slave_inactive_flags( | ||
3015 | bond->current_arp_slave); | ||
3016 | bond->current_arp_slave = NULL; | ||
3017 | } | ||
3014 | 3018 | ||
3015 | pr_info("%s: link status definitely up for interface %s.\n", | 3019 | pr_info("%s: link status definitely up for interface %s.\n", |
3016 | bond->dev->name, slave->dev->name); | 3020 | bond->dev->name, slave->dev->name); |