HomeFreeBSD

FreeBSD: Improve crypto_dispatch() handling

Description

FreeBSD: Improve crypto_dispatch() handling

Handle crypto_dispatch() return values same as crp->crp_etype errors.
On FreeBSD 12 many drivers returned same errors both ways, and lack
of proper handling for the first ended up in assertion panic later.
It was changed in FreeBSD 13, but there is no reason to not be safe.

While there, skip waiting for completion, including locking and
wakeup() call, for sessions on synchronous crypto drivers, such as
typical aesni and software.

Reviewed-by: Ryan Moeller <ryan@iXsystems.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Alexander Motin <mav@FreeBSD.org>
Sponsored-By: iXsystems, Inc.
Closes #13563

Details

Provenance
mavAuthored on Jun 17 2022, 10:38 PM
GitHub <noreply@github.com>Committed on Jun 17 2022, 10:38 PM
Parents
rGf60973998593: expose snapshot count via stat(2) of .zfs/snapshot (#13559)
Branches
Unknown
Tags
Unknown