NetBSD/sys
tls e5bd2a127e Rework opencrypto to use a spin mutex (crypto_mtx) instead of "splcrypto"
(actually splnet) and condvars instead of tsleep/wakeup.  Fix a few
miscellaneous problems and add some debugging printfs while there.

Restore set of CRYPTO_F_DONE in crypto_done() which was lost at some
point after this code came from FreeBSD -- it made it impossible to wait
properly for a condition.

Add flags analogous to the "crp" flags to the key operation's krp struct.
Add a new flag, CRYPTO_F_ONRETQ which tells us a request finished before
the kthread had a chance to dequeue it and call its callback -- this was
letting requests stick on the queues before even though done and copied
out.

Callers of crypto_newsession() or crypto_freesession() must now take the
mutex.  Change netipsec to do so.  Dispatch takes the mutex itself as
needed.

This was tested fairly extensively with the cryptosoft backend and lightly
with a new hardware driver.  It has not been tested with FAST_IPSEC; I am
unable to ascertain whether FAST_IPSEC currently works at all in our tree.

pjd@FreeBSD.ORG, ad@NetBSD.ORG, and darran@snark.us pointed me in the
right direction several times in the course of this.  Remaining bugs
are mine alone.
2008-02-04 00:35:34 +00:00
..
altq Now that __HAVE_TIMECOUNTER and __HAVE_GENERIC_TODR are invariants, 2008-01-20 18:09:03 +00:00
arch Do not panic when trying to disestablish a pci interrupt. 2008-02-03 22:51:21 +00:00
coda PR kern/37706 (forced unmount of file systems is unsafe): 2008-01-30 11:46:59 +00:00
compat Regen for pread and pwrite 2008-02-02 22:57:49 +00:00
conf defflag CPU_IN_CKSUM 2008-02-03 13:25:57 +00:00
contrib/dev/ath Use BUILDSYMLINKS from <bsd.files.mk> instead of custom copy rules 2008-01-17 01:13:01 +00:00
crypto use __KERNEL_RCSID() 2007-12-11 23:31:07 +00:00
ddb When doing a reboot from ddb, set panicstr, so that later LOCKDEBUG checks 2008-02-02 18:16:42 +00:00
dev No need to preserve RE_NTXDESC_RSVD on re_start(). 2008-02-03 17:14:35 +00:00
dist Convert rtcache_init()+rtcache_getrt() to single rtcache_init() 2008-01-14 17:17:19 +00:00
fs Remove debugging code that's no longer needed. 2008-01-31 13:13:20 +00:00
gdbscripts
ipkdb
kern Add, document, and use KAUTH_REQ_PROCESS_KTRACE_PERSISTENT. 2008-02-02 21:04:40 +00:00
lib Improve my version of mtprng_random. Reshuffle things. Add an compatible 2008-02-02 01:13:04 +00:00
lkm Add new linux_uid16.c file needed for m68k. 2008-01-17 15:10:53 +00:00
miscfs PR kern/37706 (forced unmount of file systems is unsafe): 2008-01-30 11:46:59 +00:00
modules Pull in my modules code for review/test/hacking. 2008-01-16 12:34:50 +00:00
net Fix more fall-out from extracting ifioctl_common(): don't return 2008-01-23 16:51:19 +00:00
net80211 fix 0 bssid problem on rejoin. From FreeBSD. 2008-01-31 22:07:22 +00:00
netatalk Make one call to rtcache_lookup() out of calls to rtcache_setdst() 2008-01-28 18:28:31 +00:00
netbt do not destroy session callout until the session is definitely finished 2008-01-31 19:30:23 +00:00
netinet revert tcp_output.c 1.253 because it has an ill effect when sending 2008-01-29 12:34:47 +00:00
netinet6 Refactor in_cksum/in4_cksum/in6_cksum implementations: 2008-01-25 21:12:10 +00:00
netipsec Rework opencrypto to use a spin mutex (crypto_mtx) instead of "splcrypto" 2008-02-04 00:35:34 +00:00
netisdn __FUNCTION__ -> __func__ 2007-12-15 00:39:14 +00:00
netiso Use rtcache_validate() instead of rtcache_getrt(). 2008-01-14 04:17:35 +00:00
netkey s/DIGAGNOSTIC/DIAGNOSTIC/ 2008-01-13 10:45:19 +00:00
netnatm Use struct initializers. No functional change. 2007-12-07 19:46:18 +00:00
netsmb Replace crufty use of lockmgr. 2008-01-30 14:08:00 +00:00
nfs PR kern/37706 (forced unmount of file systems is unsafe): 2008-01-30 11:46:59 +00:00
opencrypto Rework opencrypto to use a spin mutex (crypto_mtx) instead of "splcrypto" 2008-02-04 00:35:34 +00:00
rump Make it compile. 2008-01-30 14:57:24 +00:00
secmodel Add, document, and use KAUTH_REQ_PROCESS_KTRACE_PERSISTENT. 2008-02-02 21:04:40 +00:00
stand
sys Add, document, and use KAUTH_REQ_PROCESS_KTRACE_PERSISTENT. 2008-02-02 21:04:40 +00:00
ufs Make it work after lockmgr -> vlockmgr conversion: 2008-01-30 17:20:04 +00:00
uvm Lock swapdev_vp for VOP_OPEN. 2008-01-30 14:25:21 +00:00
Makefile