summaryrefslogtreecommitdiffstats
path: root/sys/net/if_lagg.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/net/if_lagg.c')
-rw-r--r--sys/net/if_lagg.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/sys/net/if_lagg.c b/sys/net/if_lagg.c
index e7cfb3c..8d53526 100644
--- a/sys/net/if_lagg.c
+++ b/sys/net/if_lagg.c
@@ -445,7 +445,11 @@ lagg_capabilities(struct lagg_softc *sc)
struct lagg_port *lp;
int cap = ~0, ena = ~0;
u_long hwa = ~0UL;
- u_int hw_tsomax = IF_HW_TSOMAX_DEFAULT_VALUE();
+#if defined(INET) || defined(INET6)
+ u_int hw_tsomax = IP_MAXPACKET; /* Initialize to the maximum value. */
+#else
+ u_int hw_tsomax = ~0; /* if_hw_tsomax is only for INET/INET6, but.. */
+#endif
LAGG_WLOCK_ASSERT(sc);
@@ -454,9 +458,10 @@ lagg_capabilities(struct lagg_softc *sc)
cap &= lp->lp_ifp->if_capabilities;
ena &= lp->lp_ifp->if_capenable;
hwa &= lp->lp_ifp->if_hwassist;
- /* Set to the common value of the lagg ports. */
- hw_tsomax = if_hw_tsomax_common(hw_tsomax,
- lp->lp_ifp->if_hw_tsomax);
+ /* Set to the minimum value of the lagg ports. */
+ if (lp->lp_ifp->if_hw_tsomax < hw_tsomax &&
+ lp->lp_ifp->if_hw_tsomax > 0)
+ hw_tsomax = lp->lp_ifp->if_hw_tsomax;
}
cap = (cap == ~0 ? 0 : cap);
ena = (ena == ~0 ? 0 : ena);
OpenPOWER on IntegriCloud