FROMGIT: crypto: speck - export common helpers
authorEric Biggers <ebiggers@google.com>
Wed, 14 Feb 2018 18:42:20 +0000 (10:42 -0800)
committerEric Biggers <ebiggers@google.com>
Thu, 22 Feb 2018 21:22:10 +0000 (13:22 -0800)
commitb456daecc73ca80d8e0e2c1afdf5b1fd2ed695b2
treecbbea8756327280c5ce26bb4ba28514cc90c745e
parent1b5dd7104e24af451c311c6d1222a0d4ed5f05ba
FROMGIT: crypto: speck - export common helpers

Export the Speck constants and transform context and the ->setkey(),
->encrypt(), and ->decrypt() functions so that they can be reused by the
ARM NEON implementation of Speck-XTS.  The generic key expansion code
will be reused because it is not performance-critical and is not
vectorizable, while the generic encryption and decryption functions are
needed as fallbacks and for the XTS tweak encryption.

Signed-off-by: Eric Biggers <ebiggers@google.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
(cherry picked from commit c8c36413ca8ccbf7a0afe71247fc4617ee2dfcfe
 git://git.kernel.org/pub/scm/linux/kernel/git/herbert/cryptodev-2.6.git master)
Change-Id: I93e96e1ef40de7071af212146b8ad3bf45297c1d
Signed-off-by: Eric Biggers <ebiggers@google.com>
crypto/speck.c
include/crypto/speck.h [new file with mode: 0644]