svn commit: r210263 - head/sys/dev/bce

Pyun YongHyeon yongari at FreeBSD.org
Mon Jul 19 21:41:55 UTC 2010


Author: yongari
Date: Mon Jul 19 21:41:54 2010
New Revision: 210263
URL: http://svn.freebsd.org/changeset/base/210263

Log:
  Do not report current link state if interface is not UP.
  
  Reviewed by:	davidch

Modified:
  head/sys/dev/bce/if_bce.c

Modified: head/sys/dev/bce/if_bce.c
==============================================================================
--- head/sys/dev/bce/if_bce.c	Mon Jul 19 21:38:15 2010	(r210262)
+++ head/sys/dev/bce/if_bce.c	Mon Jul 19 21:41:54 2010	(r210263)
@@ -5855,6 +5855,10 @@ bce_ifmedia_sts(struct ifnet *ifp, struc
 
 	BCE_LOCK(sc);
 
+	if ((ifp->if_flags & IFF_UP) == 0) {
+		BCE_UNLOCK(sc);
+		return;
+	}
 	mii = device_get_softc(sc->bce_miibus);
 
 	mii_pollstat(mii);


More information about the svn-src-head mailing list