Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/ic use callout_destroy in malo_detach, not callout_stop



details:   https://anonhg.NetBSD.org/src/rev/c4ed319382d8
branches:  trunk
changeset: 446691:c4ed319382d8
user:      jakllsch <jakllsch%NetBSD.org@localhost>
date:      Fri Dec 14 21:23:43 2018 +0000

description:
use callout_destroy in malo_detach, not callout_stop

diffstat:

 sys/dev/ic/malo.c |  9 ++++-----
 1 files changed, 4 insertions(+), 5 deletions(-)

diffs (31 lines):

diff -r a01b5fd340a2 -r c4ed319382d8 sys/dev/ic/malo.c
--- a/sys/dev/ic/malo.c Fri Dec 14 20:44:36 2018 +0000
+++ b/sys/dev/ic/malo.c Fri Dec 14 21:23:43 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: malo.c,v 1.14 2018/12/14 20:44:36 jakllsch Exp $ */
+/*     $NetBSD: malo.c,v 1.15 2018/12/14 21:23:43 jakllsch Exp $ */
 /*     $OpenBSD: malo.c,v 1.92 2010/08/27 17:08:00 jsg Exp $ */
 
 /*
@@ -19,7 +19,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: malo.c,v 1.14 2018/12/14 20:44:36 jakllsch Exp $");
+__KERNEL_RCSID(0, "$NetBSD: malo.c,v 1.15 2018/12/14 21:23:43 jakllsch Exp $");
 
 #include <sys/param.h>
 #include <sys/types.h>
@@ -470,10 +470,9 @@
        struct ieee80211com *ic = &sc->sc_ic;
        struct ifnet *ifp = &sc->sc_if;
 
+       malo_stop(ifp, 1);
        /* remove channel scanning timer */
-       callout_stop(&sc->sc_scan_to);
-
-       malo_stop(ifp, 1);
+       callout_destroy(&sc->sc_scan_to);
        ieee80211_ifdetach(ic);
        if_detach(ifp);
        malo_free_cmd(sc);



Home | Main Index | Thread Index | Old Index