[PATCH 0/4] crypto: iaa - Fixes for multi entry SG lists

From: Vinicius Costa Gomes

Date: Tue Jul 14 2026 - 00:11:23 EST


Since commit e2c3b6b21c77 ("mm: zswap: use SG list decompression APIs
from zsmalloc"), iaa_crypto started seeing some failures with
multi-entry scatter lists.

For that we introduce software fallback, in patch 2/4, to iaa-crypto
when SG lists have more than one entry, for both input and output.
Patch 4/4 adds a bounce buffer so small/simple requests can be
linearized and sent to the hardware. This recovers most of the
performance.

Patch 1/4 updates the default resources reserved to iaa-crypto so more
engines are associated to the iaa_crypto group, resulting in better
utilization by default. Patch 3/4 fixes so software requests are not
double counted. As the idxd changes only affect iaa_crypto, sending
them here makes more sense.

It should be noted that as the software and hardware implementations
have different expectations for the window size, something like patch
[1] or the future 'set_params()' API are needed to verify that patch
2/4 works without patch 4/4.

[1] https://lore.kernel.org/linux-crypto/20260326100433.57324-1-giovanni.cabiddu@xxxxxxxxx/

Cheers,

Signed-off-by: Vinicius Costa Gomes <vinicius.gomes@xxxxxxxxx>
---
Giovanni Cabiddu (4):
dmaengine: idxd: assign all engines to group 0 in IAA defaults
crypto: iaa - fall back to software for multi-entry scatterlists
crypto: iaa - avoid counting fallback decompression bytes
crypto: iaa - use bounce buffer for multi-sg decompress input

drivers/crypto/intel/iaa/iaa_crypto_main.c | 236 ++++++++++++++++++++--------
drivers/crypto/intel/iaa/iaa_crypto_stats.c | 11 +-
drivers/crypto/intel/iaa/iaa_crypto_stats.h | 2 +
drivers/dma/idxd/defaults.c | 12 +-
4 files changed, 186 insertions(+), 75 deletions(-)
---
base-commit: b73b71df4cb4ca241165ad31218c82dfe489147c
change-id: 20260713-iaa-crypto-fixes-zswap-ff5baae311d1

Best regards,
--
Vinicius