Module Name: src
Committed By: skrll
Date: Sat Dec 17 15:30:34 UTC 2016
Modified Files:
src/sys/dev/usb [nick-nhusb]: if_athn_usb.c
Log Message:
Call {mutex,cv}_destroy on all mutexes/condvars
To generate a diff of this commit:
cvs rdiff -u -r1.6.8.14 -r1.6.8.15 src/sys/dev/usb/if_athn_usb.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/dev/usb/if_athn_usb.c
diff -u src/sys/dev/usb/if_athn_usb.c:1.6.8.14 src/sys/dev/usb/if_athn_usb.c:1.6.8.15
--- src/sys/dev/usb/if_athn_usb.c:1.6.8.14 Sun Dec 11 15:10:43 2016
+++ src/sys/dev/usb/if_athn_usb.c Sat Dec 17 15:30:34 2016
@@ -1,4 +1,4 @@
-/* $NetBSD: if_athn_usb.c,v 1.6.8.14 2016/12/11 15:10:43 skrll Exp $ */
+/* $NetBSD: if_athn_usb.c,v 1.6.8.15 2016/12/17 15:30:34 skrll Exp $ */
/* $OpenBSD: if_athn_usb.c,v 1.12 2013/01/14 09:50:31 jsing Exp $ */
/*-
@@ -22,7 +22,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_athn_usb.c,v 1.6.8.14 2016/12/11 15:10:43 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_athn_usb.c,v 1.6.8.15 2016/12/17 15:30:34 skrll Exp $");
#ifdef _KERNEL_OPT
#include "opt_inet.h"
@@ -499,8 +499,15 @@ athn_usb_detach(device_t self, int flags
athn_usb_close_pipes(usc);
mutex_destroy(&usc->usc_tx_mtx);
- mutex_destroy(&usc->usc_task_mtx);
cv_destroy(&usc->usc_task_cv);
+ mutex_destroy(&usc->usc_task_mtx);
+
+ mutex_destroy(&usc->usc_cmd_mtx);
+ cv_destroy(&usc->usc_cmd_cv);
+ mutex_destroy(&usc->usc_msg_mtx);
+ cv_destroy(&usc->usc_msg_cv);
+
+ mutex_destroy(&usc->usc_lock);
usbd_add_drv_event(USB_EVENT_DRIVER_DETACH, usc->usc_udev, sc->sc_dev);
return 0;