Unlock the main lock before returning rather than after to eliminate

dead code that shouldn't have been dead.

Reported by: Maxime Villard
This commit is contained in:
Warner Losh 2015-03-01 21:41:33 +00:00
parent 3846dae834
commit 679f3f62a8
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=279500

View File

@ -1172,8 +1172,8 @@ ed_ifmedia_sts(struct ifnet *ifp, struct ifmediareq *ifmr)
sc = ifp->if_softc;
ED_LOCK(sc);
if (sc->miibus == NULL) {
return;
ED_UNLOCK(sc);
return;
}
mii = device_get_softc(sc->miibus);