freebsd-skq/sys
John Baldwin 8d768e7676 Rework witness_lock() to make it slightly more useful and flexible.
- witness_lock() is split into two pieces: witness_checkorder() and
  witness_lock().  Witness_checkorder() determines if acquiring a specified
  lock at the time it is called would result in a lock order.  It
  optionally adds a new lock order relationship as well.  witness_lock()
  updates witness's data structures to assume that a lock has been acquired
  by stick a new lock instance in the appropriate lock instance list.
- The mutex and sx lock functions now call checkorder() prior to trying to
  acquire a lock and continue to call witness_lock() after the acquire is
  completed.  This will let witness catch a deadlock before it happens
  rather than trying to do so after the threads have deadlocked (i.e. never
  actually report it).
- A new function witness_defineorder() has been added that adds a lock
  order between two locks at runtime without having to acquire the locks.
  If the lock order cannot be added it will return an error.  This function
  is available to programmers via the WITNESS_DEFINEORDER() macro which
  accepts either two mutexes or two sx locks as its arguments.
- A few simple wrapper macros were added to allow developers to call
  witness_checkorder() anywhere as a way of enforcing locking assertions
  in code that might acquire a certain lock in some situations.  The
  macros are: witness_check_{mutex,shared_sx,exclusive_sx} and take an
  appropriate lock as the sole argument.
- The code to remove a lock instance from a lock list in witness_unlock()
  was unnested by using a goto to vastly improve the readability of this
  function.
2004-01-28 20:39:57 +00:00
..
alpha - Remove local changes that leaked into my last commit. 2004-01-24 21:45:25 +00:00
amd64 MFi386 revision 1.230 2004-01-25 06:19:37 +00:00
arm Add sysentvec->sv_fixlimits() hook so that we can catch cases on 64 bit 2003-09-25 01:10:26 +00:00
boot MFi386: revision 1.33 2004-01-28 04:15:31 +00:00
cam Fix type in comment, 's/writtent/written/' 2004-01-18 00:17:14 +00:00
coda - Implement selwakeuppri() which allows raising the priority of a 2003-11-09 09:17:26 +00:00
compat Implement NdisVirtualBufferAddress() and NdisVirtualBufferAddressSafe(). 2004-01-27 08:10:34 +00:00
conf Add missing 'device ataraid' to support ATA software RAID. 2004-01-26 16:38:33 +00:00
contrib This commit was generated by cvs2svn to compensate for changes in r124528, 2004-01-14 18:54:22 +00:00
crypto Fix a reentrancy issue in md5_calc(). 2004-01-27 18:57:21 +00:00
ddb If not in the debugger or if the user requests it with the 2004-01-28 06:51:18 +00:00
dev Use the biotask functionality in GEOM to put finished requests on 2004-01-28 20:38:51 +00:00
fs Fix style(9) of my previous commit. 2004-01-21 18:03:54 +00:00
geom Bring back the geom_bioqueues, they _are_ a good idea. 2004-01-28 08:39:18 +00:00
gnu Copy workaround from FFS: open device for write access even if 2004-01-24 08:43:06 +00:00
i4b Based on an excellent suggestion from tanimura@ define I4BPRI and use it 2003-11-10 14:20:34 +00:00
i386 Remove process lock XXX's, fixed in src/sys/sys/proc.h:1.366. 2004-01-28 06:48:31 +00:00
ia64 Sort PFIL_HOOKS. 2004-01-27 20:22:53 +00:00
isa Significantly reduce the "jitter" that is typical for PS/2 mice 2003-12-11 11:28:11 +00:00
isofs/cd9660 Spell magic '16' number as IO_SEQSHIFT. 2004-01-19 20:03:43 +00:00
kern Rework witness_lock() to make it slightly more useful and flexible. 2004-01-28 20:39:57 +00:00
libkern Translate from GNU C to ISO C. 2004-01-14 07:47:10 +00:00
modules Always build ext2fs module. There is no written policy preventing the 2004-01-28 04:16:13 +00:00
net Cleanup malloc() use in if_attach(): 2004-01-27 19:35:05 +00:00
net80211 Change WI_RID_SCAN_RES compatibility interface to return the result after 2004-01-19 05:25:43 +00:00
netatalk Eliminate a duplicate free when deleting an interface address. This 2003-11-28 04:19:41 +00:00
netatm Introduce a MAC label reference in 'struct inpcb', which caches 2003-11-18 00:39:07 +00:00
netgraph Correct the description of the net.graph.recvspace sysctl. 2004-01-27 22:02:01 +00:00
netinet Correct the descriptions of the net.inet.{udp,raw}.recvspace sysctls. 2004-01-27 22:17:39 +00:00
netinet6 protect access to ifnet structure with mutex. 2004-01-28 15:01:39 +00:00
netipsec o add missing break 2004-01-27 17:45:28 +00:00
netipx Introduce a MAC label reference in 'struct inpcb', which caches 2003-11-18 00:39:07 +00:00
netkey avoid duplicate free. 2004-01-25 17:18:12 +00:00
netnatm Introduce a MAC label reference in 'struct inpcb', which caches 2003-11-18 00:39:07 +00:00
netncp The present defaults for the open and close for device drivers which 2003-09-27 12:01:01 +00:00
netsmb Add support for SMB request signing, which prevents "man in the middle" 2004-01-02 22:38:42 +00:00
nfs University of Michigan's Citi NFSv4 kernel client code. 2003-11-14 20:54:10 +00:00
nfs4client This patch fixes two little portability (to !GCC compilers) problems: 2003-12-11 11:30:26 +00:00
nfsclient Use function pointers to remove the depenancy cross dependancy on nfs4 2003-11-22 02:21:49 +00:00
nfsserver Fix some becuase -> because typos. 2003-12-17 16:12:01 +00:00
opencrypto style(9) pass and type fixups. 2003-12-16 14:13:47 +00:00
pc98 The ataraid device is not needed for pc98. 2004-01-27 15:39:32 +00:00
pccard - Implement selwakeuppri() which allows raising the priority of a 2003-11-09 09:17:26 +00:00
pci Fix multicast and promiscuous mode handling for Yukon devices. 2004-01-21 22:32:15 +00:00
posix4 sched_setscheduler: Return EINVAL when a invalid policy is specified, 2003-09-13 18:46:24 +00:00
powerpc - Recruit some new ULE users by making it the default scheduler in GENERIC. 2004-01-24 21:38:52 +00:00
rpc Don't panic because of RPC proto mismatches. Whitespace cleanup. 2004-01-17 21:25:05 +00:00
security Pay attention to mac_portacl_enabled. 2004-01-20 18:33:02 +00:00
sparc64 - Fix for sparc64 to use new __panic() function 2004-01-27 15:02:18 +00:00
sys Rework witness_lock() to make it slightly more useful and flexible. 2004-01-28 20:39:57 +00:00
tools Changes for new SMP-safe kobj method dispatch algorithm. 2003-10-16 13:29:26 +00:00
ufs Turn uio_resid/uio_offset comments into KASSERTs 2004-01-27 11:28:38 +00:00
vm - Add a flags parameter to mi_switch. The value of flags may be SW_VOL or 2004-01-25 03:54:52 +00:00
Makefile Replaced outdated comment. 2004-01-17 03:28:27 +00:00