| 5bdb8b27 | 18-Jan-2021 |
Mark Johnston <markj@FreeBSD.org> |
safexcel: Maintain per-session context records
The context record contains key material precomputed by the driver at session creation time. Rather than storing various components of the context rec
safexcel: Maintain per-session context records
The context record contains key material precomputed by the driver at session creation time. Rather than storing various components of the context record in each session, go a bit further and store the full context record image so that safexcel_process() can simply copy the image into each request submitted to the hardware. This simplifies the data path and eliminates a bunch of unnecessary conditional logic that was getting executed for each request.
MFC after: 1 week Sponsored by: Rubicon Communications, LLC (Netgate)
show more ...
|
| 1a6ffed5 | 18-Jan-2021 |
Mark Johnston <markj@FreeBSD.org> |
safexcel: Simplify request allocation
Rather than preallocating a set of requests and moving them between queues during state transitions, maintain a shadow of the command descriptor ring to track t
safexcel: Simplify request allocation
Rather than preallocating a set of requests and moving them between queues during state transitions, maintain a shadow of the command descriptor ring to track the driver context of each request. This is simpler and requires less synchronization between safexcel_process() and the ring interrupt handler.
MFC after: 1 week Sponsored by: Rubicon Communications, LLC (Netgate)
show more ...
|
| b7e27af3 | 18-Jan-2021 |
Mark Johnston <markj@FreeBSD.org> |
safexcel: Handle command/result descriptor exhaustion gracefully
Rather than returning a hard error in this case, return ERESTART so that upper layers get a chance to retry the request (or drop it,
safexcel: Handle command/result descriptor exhaustion gracefully
Rather than returning a hard error in this case, return ERESTART so that upper layers get a chance to retry the request (or drop it, depending on the desired policy).
This case is hard to hit due to the somewhat low bound on queued requests, but that will no longer be true after an upcoming change.
MFC after: 1 week Sponsored by: Rubicon Communications, LLC (Netgate)
show more ...
|
| 092cf8d6 | 08-Jan-2021 |
Mark Johnston <markj@FreeBSD.org> |
safexcel: Fix a race around unblocking of crypto ops
safexcel_ring_intr() could fail to observed that sc_blocked is set after completing all outstanding ops for a ring, in which case blocked ops wou
safexcel: Fix a race around unblocking of crypto ops
safexcel_ring_intr() could fail to observed that sc_blocked is set after completing all outstanding ops for a ring, in which case blocked ops would be deferred forever.
Request structures are managed by individual rings, so move the "blocked" flag into the per-ring state block and use the ring lock to synchronize with safexcel_process(). Remove sc_mtx since it is now unused.
MFC after: 3 days Sponsored by: Rubicon Communications, LLC (Netgate)
show more ...
|