Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 20 Jun 2017 18:14:56 +0000 (UTC)
From:      Luiz Otavio O Souza <loos@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r320158 - head/sys/dev/neta
Message-ID:  <201706201814.v5KIEuS4067123@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: loos
Date: Tue Jun 20 18:14:56 2017
New Revision: 320158
URL: https://svnweb.freebsd.org/changeset/base/320158

Log:
  Allow the use of extended media types with if_mvneta, so it can report 2.5G
  speeds properly.
  
  While here remove a couple of stray white spaces.
  
  Sponsored by:	Rubicon Communications, LLC (Netgate)

Modified:
  head/sys/dev/neta/if_mvneta.c

Modified: head/sys/dev/neta/if_mvneta.c
==============================================================================
--- head/sys/dev/neta/if_mvneta.c	Tue Jun 20 18:11:23 2017	(r320157)
+++ head/sys/dev/neta/if_mvneta.c	Tue Jun 20 18:14:56 2017	(r320158)
@@ -2100,6 +2100,7 @@ mvneta_ioctl(struct ifnet *ifp, u_long cmd, caddr_t da
 			break;
 		}
 	case SIOCGIFMEDIA: /* FALLTHROUGH */
+	case SIOCGIFXMEDIA:
 		if (!sc->phy_attached)
 			error = ifmedia_ioctl(ifp, ifr, &sc->mvneta_ifmedia,
 			    cmd);
@@ -2469,7 +2470,7 @@ mvneta_adjust_link(struct mvneta_softc *sc)
 		mvneta_linkupdate(sc, phy_linkup);
 
 	/* Don't update media on disabled link */
-	if (!phy_linkup )
+	if (!phy_linkup)
 		return;
 
 	/* Check for media type change */
@@ -3547,7 +3548,7 @@ mvneta_update_mib(struct mvneta_softc *sc)
 	if_inc_counter(sc->ifp, IFCOUNTER_IQDROPS, reg);
 
 	/* TX watchdog. */
-	if (sc->counter_watchdog_mib > 0 ) {
+	if (sc->counter_watchdog_mib > 0) {
 		if_inc_counter(sc->ifp, IFCOUNTER_OERRORS, sc->counter_watchdog_mib);
 		sc->counter_watchdog_mib = 0;
 	}



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201706201814.v5KIEuS4067123>