opnsense-src/sys/dev/cxgbe/crypto
John Baldwin 12978b1c99 ccr: Use a software OCF session for requests which fallback to software.
Previously the driver duplicated code from cryptosoft.c to handle
certain edge case AES-CCM and AES-GCM requests.  However, this
approach has a few downsides:

1) It only uses "plain" software and not accelerated software since it
   uses enc_xform directly.

2) It performs the operation synchronously even though the caller
   believes it is invoking an async driver.  This was fine for the
   original use case of requests with only AAD and no payload that
   execute quickly, but is a bit more disingenuous for large requests
   which fall back due to exceeding the size of a firmware work
   request (e.g. due to large scatter/gather lists).

3) It has required several updates since ccr(4) was added to the tree.

Instead, allocate a software session for AES-CCM and AES-GCM sessions
and dispatch a cloned request asynchronusly to the software session.

Reviewed by:	markj
Sponsored by:	Chelsio Communications
Differential Revision:	https://reviews.freebsd.org/D33608

(cherry picked from commit e43cf698d9)
2022-04-29 15:50:29 -07:00
..
t4_crypto.c ccr: Use a software OCF session for requests which fallback to software. 2022-04-29 15:50:29 -07:00
t4_crypto.h Add support for AES-CCM to ccr(4). 2019-04-24 23:31:46 +00:00
t4_kern_tls.c cxgbe(4): Overhaul CLIP (Compressed Local IPv6) table management. 2021-10-20 10:05:02 -07:00
t4_keyctx.c Explicitly zero AES key schedules on the stack. 2020-06-03 22:18:21 +00:00