Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

crypto: arm/curve25519 - add arch-specific key generation function

Somehow this was forgotten when Zinc was being split into oddly shaped
pieces, resulting in linker errors. The x86_64 glue has a specific key
generation implementation, but the Arm one does not. However, it can
still receive the NEON speedups by calling the ordinary DH function
using the base point.

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Acked-by: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>

authored by

Jason A. Donenfeld and committed by
Herbert Xu
84faa307 8a6b8f4d

+7
+7
arch/arm/crypto/curve25519-glue.c
··· 38 38 } 39 39 EXPORT_SYMBOL(curve25519_arch); 40 40 41 + void curve25519_base_arch(u8 pub[CURVE25519_KEY_SIZE], 42 + const u8 secret[CURVE25519_KEY_SIZE]) 43 + { 44 + return curve25519_arch(pub, secret, curve25519_base_point); 45 + } 46 + EXPORT_SYMBOL(curve25519_base_arch); 47 + 41 48 static int curve25519_set_secret(struct crypto_kpp *tfm, const void *buf, 42 49 unsigned int len) 43 50 {