summaryrefslogtreecommitdiffstats
path: root/sys/sys/param.h
diff options
context:
space:
mode:
authorhselasky <hselasky@FreeBSD.org>2016-09-12 10:14:30 +0000
committerhselasky <hselasky@FreeBSD.org>2016-09-12 10:14:30 +0000
commita1a22a6289df77ce21f083b6b8f3334eaeba390e (patch)
tree296e7778360b96185b83ef1a47f4015819c4598d /sys/sys/param.h
parent860932ee33fe82330891c9acc939827c05f20999 (diff)
downloadFreeBSD-src-a1a22a6289df77ce21f083b6b8f3334eaeba390e.zip
FreeBSD-src-a1a22a6289df77ce21f083b6b8f3334eaeba390e.tar.gz
MFC r305421:
Resolve deadlock between device_detach() and usbd_do_request_flags() by reviving the SX control request lock and refining which lock protects the common scratch area in "struct usb_device". The SX control request lock was removed by r246759 because it caused a lock order reversal with the USB enumeration lock inside usbd_transfer_setup() as a function of r246616. It was thought that reducing the number of locks would resolve the LOR, but because some USB device drivers use usbd_do_request_flags() inside callback functions, like in taskqueues, a deadlock may occur when these are drained from device_detach(). By restoring the SX control request lock usbd_do_request_flags() is allowed to complete its execution when a USB device driver is detaching. By using the SX control request lock to protect the scratch area, the LOR introduced by r246616 is also resolved. Bump the FreeBSD version while at it to force recompilation of all USB kernel modules. Found by: avos@
Diffstat (limited to 'sys/sys/param.h')
-rw-r--r--sys/sys/param.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/sys/param.h b/sys/sys/param.h
index b539a62..15b3002 100644
--- a/sys/sys/param.h
+++ b/sys/sys/param.h
@@ -58,7 +58,7 @@
* in the range 5 to 9.
*/
#undef __FreeBSD_version
-#define __FreeBSD_version 1100502 /* Master, propagated to newvers */
+#define __FreeBSD_version 1100503 /* Master, propagated to newvers */
/*
* __FreeBSD_kernel__ indicates that this system uses the kernel of FreeBSD,
OpenPOWER on IntegriCloud