teamd's LACP runner does not set the INFO_STATE_AGGREGATION bit when
there is only one slave in a team. This results in LACPDUs not being
sent with this flag set, and the team never negotiates. A Cisco Nexus
5500 switch will report the switchport in "(s)uspended" state.
This can be reproduced on some systems by booting with a LACP team with
more than one port, or by slowly adding ports to a new team on the
commandline.
Change the check from "more than 1 port" to "more than zero ports" so
that all LACP runner slaves have this bit set.
Resolves
https://github.com/jpirko/libteam/issues/15
Tested-by: Customer
Signed-off-by: Jamie Bainbridge <jamie.bainbridge(a)gmail.com>
---
teamd/teamd_runner_lacp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/teamd/teamd_runner_lacp.c b/teamd/teamd_runner_lacp.c
index dc03996863e08da3b587044560626c835e2a5fcd..e959cb3f07d5245a79cb3602956ba0d452d27788
100644
--- a/teamd/teamd_runner_lacp.c
+++ b/teamd/teamd_runner_lacp.c
@@ -905,7 +905,7 @@ static void lacp_port_actor_update(struct lacp_port *lacp_port)
state |= INFO_STATE_EXPIRED;
if (lacp_port->state == PORT_STATE_DEFAULTED)
state |= INFO_STATE_DEFAULTED;
- if (teamd_port_count(lacp_port->ctx) > 1)
+ if (teamd_port_count(lacp_port->ctx) > 0)
state |= INFO_STATE_AGGREGATION;
teamd_log_dbg("%s: lacp info state: 0x%02X.",
lacp_port->tdport->ifname,
state);
--
2.7.4