Linux cryptographic layer development
 help / color / mirror / Atom feed
From: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
To: herbert@gondor.apana.org.au
Cc: linux-crypto@vger.kernel.org, qat-linux@intel.com,
	Vlad Dronov <vdronov@redhat.com>,
	Giovanni Cabiddu <giovanni.cabiddu@intel.com>
Subject: [PATCH v3 00/10] crypto: qat - re-enable algorithms
Date: Mon,  9 May 2022 14:34:07 +0100	[thread overview]
Message-ID: <20220509133417.56043-1-giovanni.cabiddu@intel.com> (raw)

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

-- 
2.35.1


             reply	other threads:[~2022-05-09 13:34 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-09 13:34 Giovanni Cabiddu [this message]
2022-05-09 13:34 ` [PATCH v3 01/10] crypto: qat - use pre-allocated buffers in datapath Giovanni Cabiddu
2022-05-09 13:34 ` [PATCH v3 02/10] crypto: qat - refactor submission logic Giovanni Cabiddu
2022-05-09 13:34 ` [PATCH v3 03/10] crypto: qat - add backlog mechanism Giovanni Cabiddu
2022-05-09 13:34 ` [PATCH v3 04/10] crypto: qat - fix memory leak in RSA Giovanni Cabiddu
2022-05-09 13:34 ` [PATCH v3 05/10] crypto: qat - remove dma_free_coherent() for RSA Giovanni Cabiddu
2022-05-09 13:34 ` [PATCH v3 06/10] crypto: qat - remove dma_free_coherent() for DH Giovanni Cabiddu
2022-05-09 13:34 ` [PATCH v3 07/10] crypto: qat - add param check for RSA Giovanni Cabiddu
2022-05-09 13:34 ` [PATCH v3 08/10] crypto: qat - add param check for DH Giovanni Cabiddu
2022-05-09 13:34 ` [PATCH v3 09/10] crypto: qat - honor CRYPTO_TFM_REQ_MAY_SLEEP flag Giovanni Cabiddu
2022-05-09 13:34 ` [PATCH v3 10/10] crypto: qat - re-enable registration of algorithms Giovanni Cabiddu
2022-05-09 14:11   ` Greg KH
2022-05-09 14:47     ` Giovanni Cabiddu
2022-05-20  5:57 ` [PATCH v3 00/10] crypto: qat - re-enable algorithms Herbert Xu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220509133417.56043-1-giovanni.cabiddu@intel.com \
    --to=giovanni.cabiddu@intel.com \
    --cc=herbert@gondor.apana.org.au \
    --cc=linux-crypto@vger.kernel.org \
    --cc=qat-linux@intel.com \
    --cc=vdronov@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox