de: Reset chip after calling ether_ifattach()
authorSepherosa Ziehau <sephe@dragonflybsd.org>
Sun, 7 Apr 2013 04:57:49 +0000 (12:57 +0800)
committerSepherosa Ziehau <sephe@dragonflybsd.org>
Sun, 7 Apr 2013 04:59:56 +0000 (12:59 +0800)
Else the ifnet is not completely initialized

Reported-by: swildner@
sys/dev/netif/de/if_de.c

index 4d989b5..d830e0f 100644 (file)
@@ -3884,10 +3884,10 @@ tulip_attach(tulip_softc_t *sc)
     sc->tulip_flags &= ~TULIP_DEVICEPROBE;
     tulip_ifmedia_add(sc);
 
-    tulip_reset(sc);
-
     ifq_set_maxlen(&ifp->if_snd, ifqmaxlen);
     ether_ifattach(&(sc)->tulip_if, sc->tulip_enaddr, NULL);
+
+    tulip_reset(sc);
 }
 
 static void