diff --git a/sys/dev/usb/if_urtwn.c b/sys/dev/usb/if_urtwn.c index c5b794545f62..5fe1b3831ad3 100644 --- a/sys/dev/usb/if_urtwn.c +++ b/sys/dev/usb/if_urtwn.c @@ -1,4 +1,4 @@ -/* $NetBSD: if_urtwn.c,v 1.86 2020/04/16 17:18:27 nat Exp $ */ +/* $NetBSD: if_urtwn.c,v 1.87 2020/05/02 00:50:07 mrg Exp $ */ /* $OpenBSD: if_urtwn.c,v 1.42 2015/02/10 23:25:46 mpi Exp $ */ /*- @@ -25,7 +25,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: if_urtwn.c,v 1.86 2020/04/16 17:18:27 nat Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_urtwn.c,v 1.87 2020/05/02 00:50:07 mrg Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -584,6 +584,8 @@ urtwn_detach(device_t self, int flags) ieee80211_ifdetach(&sc->sc_ic); if_detach(ifp); + mutex_destroy(&sc->sc_media_mtx); + /* Close Tx/Rx pipes. Abort done by urtwn_stop. */ urtwn_close_pipes(sc); }