diff options
author | yongari <yongari@FreeBSD.org> | 2010-07-19 21:41:54 +0000 |
---|---|---|
committer | yongari <yongari@FreeBSD.org> | 2010-07-19 21:41:54 +0000 |
commit | e0c0ca83134dab5fa637e707a46195a16f964d43 (patch) | |
tree | 5283733bc838d8b3e98cd1b44be1db538d4753d0 | |
parent | 18aed410d7a454b9083404c6c8604bcebc98fdeb (diff) | |
download | FreeBSD-src-e0c0ca83134dab5fa637e707a46195a16f964d43.zip FreeBSD-src-e0c0ca83134dab5fa637e707a46195a16f964d43.tar.gz |
Do not report current link state if interface is not UP.
Reviewed by: davidch
-rw-r--r-- | sys/dev/bce/if_bce.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/dev/bce/if_bce.c b/sys/dev/bce/if_bce.c index a881c9e..c3477f8 100644 --- a/sys/dev/bce/if_bce.c +++ b/sys/dev/bce/if_bce.c @@ -5855,6 +5855,10 @@ bce_ifmedia_sts(struct ifnet *ifp, struct ifmediareq *ifmr) BCE_LOCK(sc); + if ((ifp->if_flags & IFF_UP) == 0) { + BCE_UNLOCK(sc); + return; + } mii = device_get_softc(sc->bce_miibus); mii_pollstat(mii); |