freebsd-dev/sys
Don Lewis 12be18c7d5 Fix a race condition between the main thread in aqm_pie_cleanup() and the
callout thread that can cause a kernel panic.  Always do the final cleanup
in the callout thread by passing a separate callout function for that task
to callout_reset_sbt().

Protect the ref_count decrement in the callout with DN_BH_WLOCK().  All
other ref_count manipulation is protected with this lock.

There is still a tiny window between ref_count reaching zero and the end
of the callout function where it is unsafe to unload the module.  Fixing
this would require the use of callout_drain(), but this can't be done
because dummynet holds a mutex and callout_drain() might sleep.

Remove the callout_pending(), callout_active(), and callout_deactivate()
calls from calculate_drop_prob().  They are not needed because this callout
uses callout_init_mtx().

Submitted by:	Rasool Al-Saadi <ralsaadi@swin.edu.au>
Approved by:	re (gjb)
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D6928
2016-07-05 00:53:01 +00:00
..
amd64 Update comments for the MD functions managing contexts for new 2016-06-16 12:05:44 +00:00
arm Revert the recent armv6 changes to ALIGNED_POINTER(), restoring the 2016-06-21 17:53:42 +00:00
arm64 ARM64: fix DMAP calculation 2016-06-30 04:58:19 +00:00
boot boot1.efi: fix assignment / comparison expression 2016-07-04 16:50:21 +00:00
bsm
cam Correct PERSISTENT RESERVE OUT command and populate scsi_cmd->length. 2016-06-29 16:41:37 +00:00
cddl Revert r299454 and r299448. 2016-06-30 14:55:49 +00:00
compat Fix a bug introduced in r283433. 2016-06-26 16:59:59 +00:00
conf Update 11.0 to ALPHA6. 2016-07-01 00:00:35 +00:00
contrib Virtualise ipfilter. 2016-06-30 15:01:07 +00:00
crypto Connect the SHA-512t256 and Skein hashing algorithms to ZFS 2016-05-31 04:12:14 +00:00
ddb Add a small set of logical operators to DDB command language. 2016-05-16 19:42:38 +00:00
dev Fix interrupt loop when switching from USB device to USB host mode by 2016-07-04 17:12:22 +00:00
fs Rewrite sigdeferstop(9) and sigallowstop(9) into more flexible 2016-06-26 20:07:24 +00:00
gdb
geom 1.Improve handling around last compressed block of the file, which is 2016-06-29 18:19:05 +00:00
gnu Revert changes for local testing, inadvertantly commited in r300811. 2016-05-26 23:59:42 +00:00
i386 Update comments for the MD functions managing contexts for new 2016-06-16 12:05:44 +00:00
isa sys/isa: minor spelling fixes. 2016-05-03 21:51:52 +00:00
kern Provide helper macros to detect 'non-silent SBDRY' state and to 2016-07-03 18:19:48 +00:00
kgssapi kgssapi: insignificant spelling fix. 2016-05-03 22:05:03 +00:00
libkern sys: Make use of our rounddown() macro when sys/param.h is available. 2016-04-30 14:41:18 +00:00
mips Fixed FreeBSD/mips MALTA support for QEMU 2016-06-29 23:33:44 +00:00
modules WITH_META_MODE: Avoid false-positive error due to missing .meta with build commands. 2016-06-29 22:39:22 +00:00
net Several device drivers call if_alloc() and then do further checks and 2016-06-29 05:21:25 +00:00
net80211 [net80211] teach AMRR to log the initial MCS rate as "MCS X" 2016-07-01 19:58:13 +00:00
netgraph Get closer to a VIMAGE network stack teardown from top to bottom rather 2016-06-21 13:48:49 +00:00
netinet This patch fixes two bugs related to the setting of the I-Bit 2016-06-30 06:06:35 +00:00
netinet6 Don't consider the socket when processing an incoming ICMP/ICMP6 packet, 2016-06-23 09:13:15 +00:00
netipsec Get closer to a VIMAGE network stack teardown from top to bottom rather 2016-06-21 13:48:49 +00:00
netnatm kernel: use our nitems() macro when it is available through param.h. 2016-04-19 23:48:27 +00:00
netpfil Fix a race condition between the main thread in aqm_pie_cleanup() and the 2016-07-05 00:53:01 +00:00
netsmb sys/net*: minor spelling fixes. 2016-05-03 18:05:43 +00:00
nfs NFS: spelling fixes on comments. 2016-04-29 16:07:25 +00:00
nfsclient
nfsserver
nlm When sleeping waiting for either local or remote advisory lock, 2016-06-26 20:08:42 +00:00
ofed Fix bug in iwcm that caused a panic in iw_cm_wq when krping is run 2016-06-14 20:58:05 +00:00
opencrypto sys/opencrypto: minor spelling fixes. 2016-05-06 23:37:19 +00:00
pc98 Move 'device pci' for the PCI bus driver to the MI NOTES file. 2016-04-29 23:53:55 +00:00
powerpc Fix fat-fingering: #if AIM should have been #ifdef AIM to avoid failures on 2016-06-29 16:34:56 +00:00
riscv Update comments for the MD functions managing contexts for new 2016-06-16 12:05:44 +00:00
rpc Deobfuscate cleanup path in clnt_bck_create(..) 2016-06-10 17:53:28 +00:00
security Implement AUE_PREAD and AUE_PWRITE BSM conversion support, eliminating 2016-06-13 09:22:20 +00:00
sparc64 Update comments for the MD functions managing contexts for new 2016-06-16 12:05:44 +00:00
sys Provide helper macros to detect 'non-silent SBDRY' state and to 2016-07-03 18:19:48 +00:00
teken
tests
tools
ufs arc4random() returns 0 to (2**32)−1, use an alternative to initialize 2016-05-22 14:31:20 +00:00
vm Change type of the 'dead' variable to boolean. 2016-07-03 00:08:17 +00:00
x86 Add a tunable to disable migration of MSI-X interrupts. 2016-06-24 22:49:32 +00:00
xdr RPC: for pointers replace 0 with NULL. 2016-04-14 17:06:37 +00:00
xen xen: Correct typo in #undef for symbol NBPL 2016-06-06 14:55:46 +00:00
Makefile