svn commit: r212100 - head/sys/net

Ed Maste emaste at FreeBSD.org
Wed Sep 1 16:53:38 UTC 2010


Author: emaste
Date: Wed Sep  1 16:53:38 2010
New Revision: 212100
URL: http://svn.freebsd.org/changeset/base/212100

Log:
  Add a sysctl knob to accept input packets on any link in a failover lagg.

Modified:
  head/sys/net/if_lagg.c

Modified: head/sys/net/if_lagg.c
==============================================================================
--- head/sys/net/if_lagg.c	Wed Sep  1 16:11:26 2010	(r212099)
+++ head/sys/net/if_lagg.c	Wed Sep  1 16:53:38 2010	(r212100)
@@ -162,6 +162,14 @@ static const struct {
 	{ LAGG_PROTO_NONE,		NULL }
 };
 
+SYSCTL_DECL(_net_link);
+SYSCTL_NODE(_net_link, OID_AUTO, lagg, CTLFLAG_RW, 0, "Link Aggregation");
+
+static int lagg_failover_rx_all = 0; /* Allow input on any failover links */
+SYSCTL_INT(_net_link_lagg, OID_AUTO, failover_rx_all, CTLFLAG_RW,
+    &lagg_failover_rx_all, 0,
+    "Accept input from any interface in a failover lagg");
+
 static int
 lagg_modevent(module_t mod, int type, void *data)
 {
@@ -1560,7 +1568,7 @@ lagg_fail_input(struct lagg_softc *sc, s
 	struct ifnet *ifp = sc->sc_ifp;
 	struct lagg_port *tmp_tp;
 
-	if (lp == sc->sc_primary) {
+	if (lp == sc->sc_primary || lagg_failover_rx_all) {
 		m->m_pkthdr.rcvif = ifp;
 		return (m);
 	}


More information about the svn-src-all mailing list