Skip to content

crypto: qat - re-enable algorithms

Giovanni Cabiddu linux-crypto stable 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest10 patches 3 repliesIn review
  2. v211 patches 1 replySuperseded
  3. v112 patches 13 repliesSuperseded

Changes in v3 from the cover letter

- Removed crypto: qat - set to zero DH parameters before free from set.
- Added fixes tags to patches crypto: qat - add param check for RSA and crypto: qat - add param check for DH

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/10crypto: qat - use pre-allocated buffers in datapathdrivers/crypto/qat/qat_common/qat_algs.c drivers/crypto/qat/qat_common/qat_crypto.h+61 -270 replies
2/10crypto: qat - refactor submission logicdrivers/crypto/qat/qat_common/Makefile drivers/crypto/qat/qat_common/qat_algs.c drivers/crypto/qat/qat_common/qat_algs_send.c +3 more+101 -540 replies
3/10crypto: qat - add backlog mechanismdrivers/crypto/qat/qat_common/adf_transport.c drivers/crypto/qat/qat_common/adf_transport.h drivers/crypto/qat/qat_common/adf_transport_internal.h +6 more+123 -180 replies
4/10crypto: qat - fix memory leak in RSAdrivers/crypto/qat/qat_common/qat_asym_algs.c+1 -110 replies
5/10crypto: qat - remove dma_free_coherent() for RSAdrivers/crypto/qat/qat_common/qat_asym_algs.c+60 -770 replies
6/10crypto: qat - remove dma_free_coherent() for DHdrivers/crypto/qat/qat_common/qat_asym_algs.c+34 -490 replies
7/10crypto: qat - add param check for RSAdrivers/crypto/qat/qat_common/qat_asym_algs.c+8 -00 replies
8/10crypto: qat - add param check for DHdrivers/crypto/qat/qat_common/qat_asym_algs.c+4 -00 replies
9/10crypto: qat - honor CRYPTO_TFM_REQ_MAY_SLEEP flagdrivers/crypto/qat/qat_common/qat_algs.c drivers/crypto/qat/qat_common/qat_asym_algs.c drivers/crypto/qat/qat_common/qat_crypto.h+27 -140 replies
10/10crypto: qat - re-enable registration of algorithmsdrivers/crypto/qat/qat_4xxx/adf_drv.c drivers/crypto/qat/qat_common/qat_crypto.c+0 -142 replies

Reviews trailers per patch

All 10 patches have a Reviewed-by or Acked-by.

PatchMarco ChiapperoWojciech ZiembaAdam Guerin
1/10R-b R-b
2/10R-b
3/10R-b
4/10R-b R-b
5/10R-b R-b
6/10R-b R-b
7/10R-b R-b
8/10R-b R-b
9/10R-b R-b
10/10R-b R-b R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v3 thread

Cover letter [PATCH v3 00/10] crypto: qat - re-enable algorithms

This set is an extension of a previous set called crypto: qat - fix dm-crypt related issues which aims to re-enable the algorithms in the QAT driver after [1].

This fixes a number of issues with the implementation of the QAT algs, both symmetric and asymmetric.
In particular this set enables the QAT driver to handle correctly the flags CRYPTO_TFM_REQ_MAY_BACKLOG and CRYPTO_TFM_REQ_MAY_SLEEP, fixes an hidden issue in RSA and DH which appeared after commit f5ff79fddf0e, related to the usage of dma_free_coherent() from a tasklet, and includes important fixes in the akcipher algorithms.

One item to mention is that, differently from the previous set, this one does not removes the flag CRYPTO_ALG_ALLOCATES_MEMORY which will be removed after the conversation in [2] is closed.

[1] https://lore.kernel.org/linux-crypto/YiEyGoHacN80FcOL@silpixa00400314/
[2] https://lore.kernel.org/linux-crypto/Yl6PlqyucVLCzwF5@silpixa00400314/

Changes from v2:
- Removed crypto: qat - set to zero DH parameters before free from set.
- Added fixes tags to patches crypto: qat - add param check for RSA and crypto: qat - add param check for DH

Changes from v1:
- Clarified commit message in crypto: qat - refactor submission logic to indicate why the patch should be included in stable kernels
- Removed crypto: qat - use memzero_explicit() for algs from set after feedback from Greg KH
- Replaced memzero_explicit() with memset() in crypto: qat - set to zero DH parameters before free after feedback from Greg KH

Giovanni Cabiddu (10):
crypto: qat - use pre-allocated buffers in datapath
crypto: qat - refactor submission logic
crypto: qat - add backlog mechanism
crypto: qat - fix memory leak in RSA
crypto: qat - remove dma_free_coherent() for RSA
crypto: qat - remove dma_free_coherent() for DH
crypto: qat - add param check for RSA
crypto: qat - add param check for DH
crypto: qat - honor CRYPTO_TFM_REQ_MAY_SLEEP flag
crypto: qat - re-enable registration of algorithms

 drivers/crypto/qat/qat_4xxx/adf_drv.c         |   7 -
 drivers/crypto/qat/qat_common/Makefile        |   1 +
 drivers/crypto/qat/qat_common/adf_transport.c |  11 +
 drivers/crypto/qat/qat_common/adf_transport.h |   1 +
 .../qat/qat_common/adf_transport_internal.h   |   1 +
 drivers/crypto/qat/qat_common/qat_algs.c      | 153 +++++----
 drivers/crypto/qat/qat_common/qat_algs_send.c |  86 +++++
 drivers/crypto/qat/qat_common/qat_algs_send.h |  11 +
 drivers/crypto/qat/qat_common/qat_asym_algs.c | 304 +++++++++---------
 drivers/crypto/qat/qat_common/qat_crypto.c    |  10 +-
 drivers/crypto/qat/qat_common/qat_crypto.h    |  44 +++
 11 files changed, 392 insertions(+), 237 deletions(-)
 create mode 100644 drivers/crypto/qat/qat_common/qat_algs_send.c
 create mode 100644 drivers/crypto/qat/qat_common/qat_algs_send.h
Signature · 1 line
2.35.1