summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorBrad Smith <brad@cvs.openbsd.org>2005-07-02 00:55:10 +0000
committerBrad Smith <brad@cvs.openbsd.org>2005-07-02 00:55:10 +0000
commit9a1278b5a53c8142c1c58312f35a910f74fc5e34 (patch)
tree03fe06ce3bbc80e6ecb3f42670a7b9e21f3814a4 /sys
parentf96dcfb304f263854fb109cdfafca7eddd35b8a6 (diff)
clear IFF_RUNNING & IFF_OACTIVE in stge_stop() before de-allocating resources
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/pci/if_stge.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/sys/dev/pci/if_stge.c b/sys/dev/pci/if_stge.c
index d543ae1e766..03f83e0c8e0 100644
--- a/sys/dev/pci/if_stge.c
+++ b/sys/dev/pci/if_stge.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_stge.c,v 1.16 2005/07/01 01:13:45 brad Exp $ */
+/* $OpenBSD: if_stge.c,v 1.17 2005/07/02 00:55:09 brad Exp $ */
/* $NetBSD: if_stge.c,v 1.27 2005/05/16 21:35:32 bouyer Exp $ */
/*-
@@ -1562,6 +1562,12 @@ stge_stop(struct ifnet *ifp, int disable)
*/
timeout_del(&sc->sc_timeout);
+ /*
+ * Mark the interface down and cancel the watchdog timer.
+ */
+ ifp->if_flags &= ~(IFF_RUNNING | IFF_OACTIVE);
+ ifp->if_timer = 0;
+
/* Down the MII. */
mii_down(&sc->sc_mii);
@@ -1599,12 +1605,6 @@ stge_stop(struct ifnet *ifp, int disable)
if (disable)
stge_rxdrain(sc);
-
- /*
- * Mark the interface down and cancel the watchdog timer.
- */
- ifp->if_flags &= ~(IFF_RUNNING | IFF_OACTIVE);
- ifp->if_timer = 0;
}
#if 0