From: Ethan Jackson Date: Mon, 7 Feb 2011 22:34:44 +0000 (-0800) Subject: vswitchd: LACP attached status flapped. X-Git-Tag: v1.1.0~309 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=76ab2ea7fe0fae1fcd400df43b7f02239ee38222;p=sliver-openvswitch.git vswitchd: LACP attached status flapped. A bug introduced in the switch to bit mask LACP status caused the attached status of interfaces in a LACP bond to slowly flap. --- diff --git a/vswitchd/bridge.c b/vswitchd/bridge.c index f5c5af37e..b369ced00 100644 --- a/vswitchd/bridge.c +++ b/vswitchd/bridge.c @@ -3129,7 +3129,8 @@ lacp_process_packet(const struct ofpbuf *packet, struct iface *iface) return; } - iface->lacp_status = LACP_CURRENT; + iface->lacp_status |= LACP_CURRENT; + iface->lacp_status &= ~LACP_EXPIRED; iface->lacp_rx = time_msec() + LACP_SLOW_TIME_RX; iface->lacp_actor.state = iface_get_lacp_state(iface); @@ -4702,7 +4703,8 @@ iface_set_lacp_defaulted(struct iface *iface) { memset(&iface->lacp_partner, 0, sizeof iface->lacp_partner); - iface->lacp_status = LACP_DEFAULTED; + iface->lacp_status |= LACP_DEFAULTED; + iface->lacp_status &= ~(LACP_CURRENT | LACP_EXPIRED); iface->lacp_tx = 0; iface->port->lacp_need_update = true; }