aboutsummaryrefslogtreecommitdiff
path: root/lib/lacp.c
diff options
context:
space:
mode:
authorBen Pfaff <blp@nicira.com>2011-03-21 12:49:44 -0700
committerBen Pfaff <blp@nicira.com>2011-04-01 15:52:20 -0700
commit7a6735157c0df93375e9daadf0bbd1dca4160533 (patch)
tree6f9477194e8852c6772aa07fad657aeb8e8cdaca /lib/lacp.c
parent14cff48183cfd6ea939d4d8012fde192b03eeca1 (diff)
bridge: Drop LACP configuration members from struct iface and struct port.
There's no reason that I can see to maintain this information in struct port and struct iface. It's redundant, since the lacp implementation maintains the same information.
Diffstat (limited to 'lib/lacp.c')
-rw-r--r--lib/lacp.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/lacp.c b/lib/lacp.c
index 005165fd..c8fae621 100644
--- a/lib/lacp.c
+++ b/lib/lacp.c
@@ -142,6 +142,14 @@ lacp_configure(struct lacp *lacp, const char *name,
lacp->fast = fast;
}
+/* Returns true if 'lacp' is configured in active mode, false if 'lacp' is
+ * configured for passive mode. */
+bool
+lacp_is_active(const struct lacp *lacp)
+{
+ return lacp->active;
+}
+
/* Processes 'pdu', a parsed LACP packet received on 'slave_'. This function
* should be called on all packets received on 'slave_' with Ethernet Type
* ETH_TYPE_LACP and parsable by parse_lacp_packet(). */