crypto: cipher - Add crypto_clone_cipher
authorHerbert Xu <herbert@gondor.apana.org.au>
Fri, 19 May 2023 08:28:35 +0000 (16:28 +0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Wed, 24 May 2023 10:12:33 +0000 (18:12 +0800)
commit51d8d6d0f4bedb6a4e9afb20857bb592424de144
treeb419114f9f46758e6c27b9d39cfa68ab2550fe0c
parentcf2eddc931ab6e4dd96d38bd75ef8aac3422a8f4
crypto: cipher - Add crypto_clone_cipher

Allow simple ciphers to be cloned, if they don't have a cra_init
function.  This basically rules out those ciphers that require a
fallback.

In future simple ciphers will be eliminated, and replaced with a
linear skcipher interface.  When that happens this restriction will
disappear.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Acked-by: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
crypto/cipher.c
include/crypto/internal/cipher.h