diff options
author | Brad Smith <brad@cvs.openbsd.org> | 2005-07-02 23:14:43 +0000 |
---|---|---|
committer | Brad Smith <brad@cvs.openbsd.org> | 2005-07-02 23:14:43 +0000 |
commit | d7deff1ddeb8bbe3031bc3bea7758b3f5fdb701f (patch) | |
tree | 3e14787d2c04c1172f72200dc1daec788b7d9f85 | |
parent | a12d5644f5c5a2fa21bd66dfc2c3c4f3ac228ad0 (diff) |
clear IFF_RUNNING & IFF_OACTIVE in ral_stop() before de-allocating resources.
-rw-r--r-- | sys/dev/ic/ral.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/dev/ic/ral.c b/sys/dev/ic/ral.c index 6625582f7d4..13c0a28844c 100644 --- a/sys/dev/ic/ral.c +++ b/sys/dev/ic/ral.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ral.c,v 1.55 2005/06/20 18:25:10 damien Exp $ */ +/* $OpenBSD: ral.c,v 1.56 2005/07/02 23:14:42 brad Exp $ */ /*- * Copyright (c) 2005 @@ -2715,6 +2715,10 @@ ral_stop(struct ifnet *ifp, int disable) ieee80211_new_state(ic, IEEE80211_S_INIT, -1); + sc->sc_tx_timer = 0; + ifp->if_timer = 0; + ifp->if_flags &= ~(IFF_RUNNING | IFF_OACTIVE); + /* abort Tx */ RAL_WRITE(sc, RAL_TXCSR0, RAL_ABORT_TX); @@ -2738,10 +2742,6 @@ ral_stop(struct ifnet *ifp, int disable) /* for CardBus, power down the socket */ if (disable && sc->sc_disable != NULL) (*sc->sc_disable)(sc); - - sc->sc_tx_timer = 0; - ifp->if_timer = 0; - ifp->if_flags &= ~(IFF_RUNNING | IFF_OACTIVE); } struct cfdriver ral_cd = { |