linux-crypto.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/12] crypto: caam - backlogging support
@ 2019-11-17 22:30 Iuliana Prodan
  2019-11-17 22:30 ` [PATCH 01/12] crypto: add helper function for akcipher_request Iuliana Prodan
                   ` (11 more replies)
  0 siblings, 12 replies; 42+ messages in thread
From: Iuliana Prodan @ 2019-11-17 22:30 UTC (permalink / raw)
  To: Herbert Xu, Horia Geanta, Aymen Sghaier
  Cc: David S. Miller, Tom Lendacky, Gary Hook, linux-crypto,
	linux-kernel, linux-imx, Iuliana Prodan

Integrate crypto_engine framework into CAAM, to make use of
the engine queue.
Added support for SKCIPHER, HASH, RSA and AEAD algorithms.
This is intended to be used for CAAM backlogging support.
The requests, with backlog flag (e.g. from dm-crypt) will be
listed into crypto-engine queue and processed by CAAM when free.
For better performance, crypto-engine software queue is bypassed,
if empty, and the request is sent directly to hardware. If this
returns -ENOSPC, the request is transferred to crypto-engine and
let it handle it.

While here, I've also made some refactorization.
Patch #1, adds a helper function - akcipher_request_cast, to get
an akcipher_request struct from a crypto_async_request struct.
Patches #2 - #5 include some refactorizations on caamalg, caamhash
and caampkc.
Patches #6, #7 change the return code of caam_jr_enqueue function
to -EINPROGRESS, in case of success, -ENOSPC in case the CAAM is
busy, -EIO if it cannot map the caller's descriptor and add a new
enqueue function for no backlogging requests. Also, to keep each
request information, like backlog flag, a new struct is passed as
argument to enqueue functions.
Patches #8 - #12 integrate crypto_engine into CAAM, for
SKCIPHER/AEAD/RSA/HASH algorithms.


Iuliana Prodan (12):
  crypto: add helper function for akcipher_request
  crypto: caam - refactor skcipher/aead/gcm/chachapoly {en,de}crypt
    functions
  crypto: caam - refactor ahash_done callbacks
  crypto: caam - refactor ahash_edesc_alloc
  crypto: caam - refactor RSA private key _done callbacks
  crypto: caam - change return code in caam_jr_enqueue function
  crypto: caam - refactor caam_jr_enqueue
  crypto: caam - support crypto_engine framework for SKCIPHER algorithms
  crypto: caam - bypass crypto-engine sw queue, if empty
  crypto: caam - add crypto_engine support for AEAD algorithms
  crypto: caam - add crypto_engine support for RSA algorithms
  crypto: caam - add crypto_engine support for HASH algorithms

 drivers/crypto/caam/Kconfig         |   1 +
 drivers/crypto/caam/caamalg.c       | 411 ++++++++++++++++--------------------
 drivers/crypto/caam/caamhash.c      | 323 +++++++++++++++-------------
 drivers/crypto/caam/caampkc.c       | 177 ++++++++++------
 drivers/crypto/caam/caampkc.h       |  11 +
 drivers/crypto/caam/caamrng.c       |   7 +-
 drivers/crypto/caam/intern.h        |  12 ++
 drivers/crypto/caam/jr.c            | 136 +++++++++++-
 drivers/crypto/caam/jr.h            |   4 +
 drivers/crypto/caam/key_gen.c       |   4 +-
 drivers/crypto/ccp/ccp-crypto-rsa.c |   6 -
 include/crypto/akcipher.h           |   6 +
 12 files changed, 635 insertions(+), 463 deletions(-)

-- 
2.1.0


^ permalink raw reply	[flat|nested] 42+ messages in thread

end of thread, other threads:[~2019-12-11 13:33 UTC | newest]

Thread overview: 42+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-17 22:30 [PATCH 00/12] crypto: caam - backlogging support Iuliana Prodan
2019-11-17 22:30 ` [PATCH 01/12] crypto: add helper function for akcipher_request Iuliana Prodan
2019-11-18 13:29   ` Corentin Labbe
2019-11-19 14:27   ` Horia Geanta
2019-11-19 15:10   ` Gary R Hook
2019-11-22  9:08   ` Herbert Xu
2019-11-22 10:29     ` Iuliana Prodan
2019-11-22 10:34       ` Herbert Xu
2019-11-17 22:30 ` [PATCH 02/12] crypto: caam - refactor skcipher/aead/gcm/chachapoly {en,de}crypt functions Iuliana Prodan
2019-11-19 14:41   ` Horia Geanta
2019-11-17 22:30 ` [PATCH 03/12] crypto: caam - refactor ahash_done callbacks Iuliana Prodan
2019-11-19 14:56   ` Horia Geanta
2019-11-17 22:30 ` [PATCH 04/12] crypto: caam - refactor ahash_edesc_alloc Iuliana Prodan
2019-11-19 15:05   ` Horia Geanta
2019-11-17 22:30 ` [PATCH 05/12] crypto: caam - refactor RSA private key _done callbacks Iuliana Prodan
2019-11-19 15:06   ` Horia Geanta
2019-11-17 22:30 ` [PATCH 06/12] crypto: caam - change return code in caam_jr_enqueue function Iuliana Prodan
2019-11-19 15:21   ` Horia Geanta
2019-12-10 11:56   ` Bastian Krause
2019-12-10 12:28     ` Iuliana Prodan
2019-11-17 22:30 ` [PATCH 07/12] crypto: caam - refactor caam_jr_enqueue Iuliana Prodan
2019-11-19 17:55   ` Horia Geanta
2019-11-19 22:49     ` Iuliana Prodan
2019-11-20  6:48       ` Horia Geanta
2019-11-17 22:30 ` [PATCH 08/12] crypto: caam - support crypto_engine framework for SKCIPHER algorithms Iuliana Prodan
2019-11-21 11:46   ` Horia Geanta
2019-11-22 10:33   ` Herbert Xu
2019-11-22 11:05     ` Iuliana Prodan
2019-11-22 11:09       ` Herbert Xu
2019-11-22 14:11         ` Iuliana Prodan
2019-11-22 14:31           ` Herbert Xu
2019-12-10 15:27   ` Bastian Krause
2019-12-11 12:20     ` Iuliana Prodan
2019-12-11 13:33       ` Bastian Krause
2019-11-17 22:30 ` [PATCH 09/12] crypto: caam - bypass crypto-engine sw queue, if empty Iuliana Prodan
2019-11-21 11:53   ` Horia Geanta
2019-11-17 22:30 ` [PATCH 10/12] crypto: caam - add crypto_engine support for AEAD algorithms Iuliana Prodan
2019-11-21 16:46   ` Horia Geanta
2019-11-17 22:30 ` [PATCH 11/12] crypto: caam - add crypto_engine support for RSA algorithms Iuliana Prodan
2019-11-21 16:53   ` Horia Geanta
2019-11-17 22:30 ` [PATCH 12/12] crypto: caam - add crypto_engine support for HASH algorithms Iuliana Prodan
2019-11-21 17:06   ` Horia Geanta

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).