svn commit: r330301 - stable/11/sys/net
Navdeep Parhar
np at FreeBSD.org
Sat Mar 3 00:10:38 UTC 2018
Author: np
Date: Sat Mar 3 00:10:37 2018
New Revision: 330301
URL: https://svnweb.freebsd.org/changeset/base/330301
Log:
MFC r323221:
Make LACP based lagg work with interfaces (like 100Gbps and 25Gbps) that
report extended media types.
lacp_aggregator_bandwidth() uses the media to determine the speed of the
interface and returns 0 for IFM_OTHER without the bits in the extended
range.
Reported by: kbowling@
Reviewed by: eugen_grosbein.net, mjoras@
Sponsored by: Chelsio Communications
Differential Revision: https://reviews.freebsd.org/D12188
Modified:
stable/11/sys/net/ieee8023ad_lacp.c
Directory Properties:
stable/11/ (props changed)
Modified: stable/11/sys/net/ieee8023ad_lacp.c
==============================================================================
--- stable/11/sys/net/ieee8023ad_lacp.c Fri Mar 2 23:31:55 2018 (r330300)
+++ stable/11/sys/net/ieee8023ad_lacp.c Sat Mar 3 00:10:37 2018 (r330301)
@@ -461,7 +461,11 @@ lacp_linkstate(struct lagg_port *lgp)
uint16_t old_key;
bzero((char *)&ifmr, sizeof(ifmr));
- error = (*ifp->if_ioctl)(ifp, SIOCGIFMEDIA, (caddr_t)&ifmr);
+ error = (*ifp->if_ioctl)(ifp, SIOCGIFXMEDIA, (caddr_t)&ifmr);
+ if (error != 0) {
+ bzero((char *)&ifmr, sizeof(ifmr));
+ error = (*ifp->if_ioctl)(ifp, SIOCGIFMEDIA, (caddr_t)&ifmr);
+ }
if (error != 0)
return;
More information about the svn-src-all
mailing list