opnsense-src/sys
John Baldwin 5db078a9be Fix mtx_legal2block. The only time that it is bad to block on a mutex is
if we hold a spin mutex, since we can trivially get into deadlocks if we
start switching out of processes that hold spinlocks.  Checking to see if
interrupts were disabled was a sort of cheap way of doing this since most
of the time interrupts were only disabled when holding a spin lock.  At
least on the i386.  To fix this properly, use a per-process counter
p_spinlocks that counts the number of spin locks currently held, and
instead of checking to see if interrupts are disabled in the witness code,
check to see if we hold any spin locks.  Since child processes always
start up with the sched lock magically held in fork_exit(), we initialize
p_spinlocks to 1 for child processes.  Note that proc0 doesn't go through
fork_exit(), so it starts with no spin locks held.

Consulting from:	cp
2001-03-09 07:24:17 +00:00
..
alpha Fix mtx_legal2block. The only time that it is bad to block on a mutex is 2001-03-09 07:24:17 +00:00
amd64 Fix mtx_legal2block. The only time that it is bad to block on a mutex is 2001-03-09 07:24:17 +00:00
arm/include Correct disordering which is corresponding to bde's fix to 2001-02-17 14:51:11 +00:00
boot Goodbye vn, welcome md. 2001-03-07 09:42:41 +00:00
cam o Support AUTO SENSE correctly. 2001-02-25 12:40:30 +00:00
coda Mechanical change to use <sys/queue.h> macro API instead of 2001-02-04 13:13:25 +00:00
compat Grab the process lock while calling psignal and before calling psignal. 2001-03-07 03:37:06 +00:00
compile
conf Split out the ata probes in seperate files for each bus type. 2001-03-06 21:43:46 +00:00
contrib/dev Move configuration of work_memory to oltr_init() rather than 2001-03-08 01:38:58 +00:00
crypto Initial import of AES algorithm code (aka Rijndael) from KAME. 2000-10-30 11:03:32 +00:00
ddb Use macro API for <sys/queue.h> 2000-12-30 22:06:19 +00:00
dev Remember to actually program the MAC address into the unicast filter 2001-03-07 18:52:22 +00:00
fs Fixes to track snapshot copy-on-write checking in the specinfo 2001-03-07 07:09:55 +00:00
geom Fix a braino in ccd's clone routine. 2001-01-29 06:18:14 +00:00
gnu Fixes to track snapshot copy-on-write checking in the specinfo 2001-03-07 07:09:55 +00:00
i4b Preceed/preceeding are not english words. Use precede or preceding. 2001-02-18 10:25:42 +00:00
i386 Fix mtx_legal2block. The only time that it is bad to block on a mutex is 2001-03-09 07:24:17 +00:00
ia64 Fix mtx_legal2block. The only time that it is bad to block on a mutex is 2001-03-09 07:24:17 +00:00
isa Add GVC1601 - Rockwell V.34 Plug & Play Modem 2001-03-07 14:27:56 +00:00
isofs/cd9660 Reviewed by: jlemon 2001-03-01 21:00:17 +00:00
kern Fix mtx_legal2block. The only time that it is bad to block on a mutex is 2001-03-09 07:24:17 +00:00
libkern RIP <machine/lock.h>. 2001-02-11 10:44:09 +00:00
miscfs Fixes to track snapshot copy-on-write checking in the specinfo 2001-03-07 07:09:55 +00:00
modules #if 0 out a variable only used in #if 0'd code to quiet a warning. 2001-03-06 03:07:58 +00:00
msdosfs Grab the process lock while calling psignal and before calling psignal. 2001-03-07 03:37:06 +00:00
net Protect against negative numbers as well 2001-02-26 09:52:43 +00:00
netatalk Mechanical change to use <sys/queue.h> macro API instead of 2001-02-04 13:13:25 +00:00
netatm Preceed/preceeding are not english words. Use precede and preceding. 2001-02-18 10:43:53 +00:00
netgraph Fix potential crash caused by packets with bogus ACK's. 2001-03-08 20:10:02 +00:00
netinet It was possible for ip_forward() to supply to icmp_error() 2001-03-08 19:03:26 +00:00
netinet6 More IP option length validation. 2001-02-26 03:41:13 +00:00
netipx Another round of the <sys/queue.h> FOREACH transmogriffer. 2001-02-04 16:08:18 +00:00
netkey fixed possibility of panic at key_acquire(). 2001-01-14 17:25:08 +00:00
netnatm Mechanical change to use <sys/queue.h> macro API instead of 2001-02-04 13:13:25 +00:00
netncp Implement m_getm() which will perform an "all or nothing" mbuf + cluster 2001-02-14 05:13:04 +00:00
netns * Rename M_WAIT mbuf subsystem flag to M_TRYWAIT. 2000-12-21 21:44:31 +00:00
nfs Grab the process lock while calling psignal and before calling psignal. 2001-03-07 03:37:06 +00:00
nfsclient Grab the process lock while calling psignal and before calling psignal. 2001-03-07 03:37:06 +00:00
nfsserver Switch to using a struct xucred instead of a struct xucred when not 2001-02-18 13:30:20 +00:00
ntfs Reviewed by: jlemon 2001-03-01 21:00:17 +00:00
nwfs Grab the process lock while calling psignal and before calling psignal. 2001-03-07 03:37:06 +00:00
pc98 Replaced p (undeclared) with curproc (after i386/isa/npx.c). 2001-03-08 14:25:51 +00:00
pccard Move ti1031 to the 16-bit bridge section 2001-02-07 01:16:40 +00:00
pci Remember to actually program the MAC address into the unicast filter 2001-03-07 18:52:22 +00:00
posix4 Lock need_resched with sched_lock. 2001-02-22 13:46:09 +00:00
powerpc Fix mtx_legal2block. The only time that it is bad to block on a mutex is 2001-03-09 07:24:17 +00:00
rpc
svr4 This patchset fixes a large number of file descriptor race conditions. 2000-11-18 21:01:04 +00:00
sys Fix mtx_legal2block. The only time that it is bad to block on a mutex is 2001-03-09 07:24:17 +00:00
tools Simplify this a bit so that it doesn't have to generate silly redundant 2000-12-06 06:59:38 +00:00
ufs Fixes to track snapshot copy-on-write checking in the specinfo 2001-03-07 07:09:55 +00:00
vm Unrevert the pmap_map() changes. They weren't broken on x86. 2001-03-07 05:29:21 +00:00
Makefile