• Mahesh Bandewar's avatar
    bonding: fix active-backup transition · 3f3c278c
    Mahesh Bandewar authored
    Earlier patch c4adfc82 ("bonding: make speed, duplex setting
    consistent with link state") made an attempt to keep slave state
    consistent with speed and duplex settings. Unfortunately link-state
    transition is used to change the active link especially when used
    in conjunction with mii-mon. The above mentioned patch broke that
    logic. Also when speed and duplex settings for a link are updated
    during a link-event, the link-status should not be changed to
    invoke correct transition logic.
    
    This patch fixes this issue by moving the link-state update outside
    of the bond_update_speed_duplex() fn and to the places where this fn
    is called and update link-state selectively.
    
    Fixes: c4adfc82 ("bonding: make speed, duplex setting consistent
    with link state")
    Signed-off-by: default avatarMahesh Bandewar <maheshb@google.com>
    Reviewed-by: default avatarAndy Gospodarek <andy@greyhouse.net>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    3f3c278c
bond_main.c 133 KB