freebsd-dev/sys
Conrad Meyer 1b0909d51a OpenCrypto: Convert sessions to opaque handles instead of integers
Track session objects in the framework, and pass handles between the
framework (OCF), consumers, and drivers.  Avoid redundancy and complexity in
individual drivers by allocating session memory in the framework and
providing it to drivers in ::newsession().

Session handles are no longer integers with information encoded in various
high bits.  Use of the CRYPTO_SESID2FOO() macros should be replaced with the
appropriate crypto_ses2foo() function on the opaque session handle.

Convert OCF drivers (in particular, cryptosoft, as well as myriad others) to
the opaque handle interface.  Discard existing session tracking as much as
possible (quick pass).  There may be additional code ripe for deletion.

Convert OCF consumers (ipsec, geom_eli, krb5, cryptodev) to handle-style
interface.  The conversion is largely mechnical.

The change is documented in crypto.9.

Inspired by
https://lists.freebsd.org/pipermail/freebsd-arch/2018-January/018835.html .

No objection from:	ae (ipsec portion)
Reported by:	jhb
2018-07-18 00:56:25 +00:00
..
amd64 Expand x86 struct pcpus to UMA_PCPU_ALLOC_SIZE AKA PAGE_SIZE. 2018-07-06 19:50:44 +00:00
arm Remove kernel support for armeb 2018-07-17 23:23:45 +00:00
arm64 Remove VM_FREELIST_ISADMA. It's not needed on these architectures. 2018-07-17 21:07:53 +00:00
bsm
cam remove unneeded inclusion of sys/interrupt.h from several files 2018-07-04 09:07:18 +00:00
cddl dtrace/powerpc: Correct register indices for non-indexed registers in the trapframe 2018-07-16 19:47:29 +00:00
compat Regen after r336171. 2018-07-10 14:04:52 +00:00
conf Remove kernel support for armeb 2018-07-17 23:23:45 +00:00
contrib Correct the identifier for the Unifi Security Gateway 2018-07-10 17:01:19 +00:00
crypto OpenCrypto: Convert sessions to opaque handles instead of integers 2018-07-18 00:56:25 +00:00
ddb
dev OpenCrypto: Convert sessions to opaque handles instead of integers 2018-07-18 00:56:25 +00:00
dts Add spi-max-frequency properties to all spigen nodes. This is a required 2018-06-23 22:55:22 +00:00
fs Modify the reasons for not issuing a delegation in the NFSv4.1 server. 2018-07-16 21:32:50 +00:00
gdb
geom OpenCrypto: Convert sessions to opaque handles instead of integers 2018-07-18 00:56:25 +00:00
gnu dts: Update our copy to Linux 4.17 2018-06-14 07:12:10 +00:00
i386 Restore the check for the page size extension after r332489. 2018-07-15 22:18:31 +00:00
isa
kern Add a FALLTHROUGH comment to kvprintf(). 2018-07-17 14:56:54 +00:00
kgssapi OpenCrypto: Convert sessions to opaque handles instead of integers 2018-07-18 00:56:25 +00:00
libkern Sync strlcpy with userland version, again 2018-06-21 17:35:13 +00:00
mips OpenCrypto: Convert sessions to opaque handles instead of integers 2018-07-18 00:56:25 +00:00
modules Remove kernel support for armeb 2018-07-17 23:23:45 +00:00
net Move invoking of callout_stop(&lle->lle_timer) into llentry_free(). 2018-07-17 11:33:23 +00:00
net80211 net80211: Fix ifdetach w/o ifattach, small whitespace cleanup 2018-07-10 23:30:19 +00:00
netgraph
netinet Move invoking of callout_stop(&lle->lle_timer) into llentry_free(). 2018-07-17 11:33:23 +00:00
netinet6 Move invoking of callout_stop(&lle->lle_timer) into llentry_free(). 2018-07-17 11:33:23 +00:00
netipsec OpenCrypto: Convert sessions to opaque handles instead of integers 2018-07-18 00:56:25 +00:00
netpfil pf: Fix synproxy 2018-07-14 10:14:59 +00:00
netsmb
nfs Switch RIB and RADIX_NODE_HEAD lock from rwlock(9) to rmlock(9). 2018-06-16 08:26:23 +00:00
nfsclient
nfsserver
nlm
ofed Use __FBSDID() for RCS tags in ibcore. 2018-07-17 09:47:14 +00:00
opencrypto OpenCrypto: Convert sessions to opaque handles instead of integers 2018-07-18 00:56:25 +00:00
powerpc powerpc/powernv: Make opal_i2c driver work with attached i2c drivers 2018-07-09 20:33:48 +00:00
riscv Remove VM_FREELIST_ISADMA. It's not needed on these architectures. 2018-07-17 21:07:53 +00:00
rpc Fix the server side krpc so that the kernel nfsd threads terminate. 2018-07-02 17:50:46 +00:00
security auditon(2): fix A_SETPOLICY with 64-bit values 2018-07-15 21:10:19 +00:00
sparc64 Fix a typo: change lists to list to match rest of sentence. 2018-07-17 21:18:49 +00:00
sys FreeBSD_version bump as per r336351, 2018-07-17 02:20:51 +00:00
teken
tests epoch_test: fix compile 2018-07-15 00:31:17 +00:00
tools
ufs Add needed locking for um_flags added in -r335808. 2018-07-17 04:43:58 +00:00
vm Test PGA_REFERENCED after calling pmap_ts_referenced(), rather than before, 2018-07-15 19:25:15 +00:00
x86 Use the existing MSR_BIOS_SIGN on AMD. 2018-07-13 20:56:20 +00:00
xdr
xen
Makefile