linux_dsm_epyc7002/drivers/net/bonding
Toni Peltonen 3b5b3a3331 bonding: fix 802.3ad state sent to partner when unbinding slave
Previously when unbinding a slave the 802.3ad implementation only told
partner that the port is not suitable for aggregation by setting the port
aggregation state from aggregatable to individual. This is not enough. If the
physical layer still stays up and we only unbinded this port from the bond there
is nothing in the aggregation status alone to prevent the partner from sending
traffic towards us. To ensure that the partner doesn't consider this
port at all anymore we should also disable collecting and distributing to
signal that this actor is going away. Also clear AD_STATE_SYNCHRONIZATION to
ensure partner exits collecting + distributing state.

I have tested this behaviour againts Arista EOS switches with mlx5 cards
(physical link stays up even when interface is down) and simulated
the same situation virtually Linux <-> Linux with two network namespaces
running two veth device pairs. In both cases setting aggregation to
individual doesn't alone prevent traffic from being to sent towards this
port given that the link stays up in partners end. Partner still keeps
it's end in collecting + distributing state and continues until timeout is
reached. In most cases this means we are losing the traffic partner sends
towards our port while we wait for timeout. This is most visible with slow
periodic time (LACP rate slow).

Other open source implementations like Open VSwitch and libreswitch, and
vendor implementations like Arista EOS, seem to disable collecting +
distributing to when doing similar port disabling/detaching/removing change.
With this patch kernel implementation would behave the same way and ensure
partner doesn't consider our actor viable anymore.

Signed-off-by: Toni Peltonen <peltzi@peltzi.fi>
Signed-off-by: Jay Vosburgh <jay.vosburgh@canonical.com>
Acked-by: Jonathan Toppins <jtoppins@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2018-11-30 13:21:04 -08:00
..
bond_3ad.c bonding: fix 802.3ad state sent to partner when unbinding slave 2018-11-30 13:21:04 -08:00
bond_alb.c bonding: allow use of tx hashing in balance-alb 2018-05-16 12:15:11 -04:00
bond_debugfs.c License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
bond_main.c bonding/802.3ad: fix link_failure_count tracking 2018-11-04 16:44:44 -08:00
bond_netlink.c bonding: fix length of actor system 2018-10-29 20:39:38 -07:00
bond_options.c bonding: set default miimon value for non-arp modes if not set 2018-07-21 10:26:21 -07:00
bond_procfs.c bonding: switch to proc_create_seq_data 2018-05-16 07:24:30 +02:00
bond_sysfs_slave.c drivers/net: Use octal not symbolic permissions 2018-03-26 12:07:49 -04:00
bond_sysfs.c bonding: don't cast const buf in sysfs store 2018-07-22 10:09:30 -07:00
bonding_priv.h net/bonding: Make DRV macros private 2015-04-26 22:59:53 -04:00
Makefile bonding: add sysfs /slave dir for bond slave devices. 2014-01-17 18:51:58 -08:00