linux/lib/crypto
Ard Biesheuvel ba89b4eaa6 crypto: lib/chachapoly - Drop dependency on CRYPTO_ALGAPI
The ChaCha20-Poly1305 library code uses the sg_miter API to process
input presented via scatterlists, except for the special case where the
digest buffer is not covered entirely by the same scatterlist entry as
the last byte of input. In that case, it uses scatterwalk_map_and_copy()
to access the memory in the input scatterlist where the digest is stored.

This results in a dependency on crypto/scatterwalk.c and therefore on
CONFIG_CRYPTO_ALGAPI, which is unnecessary, as the sg_miter API already
provides this functionality via sg_copy_to_buffer(). So use that
instead, and drop the dependencies on CONFIG_CRYPTO_ALGAPI and
CONFIG_CRYPTO.

Reported-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Eric Biggers <ebiggers@kernel.org>
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
History 2025-03-08 16:24:36 +08:00
..
mpi crypto: lib/mpi - Export mpi_set_bit 2024-11-15 19:52:51 +08:00
aes.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
aescfb.c crypto: lib - implement library version of AES in CFB mode 2024-05-09 22:30:51 +03:00
aesgcm.c crypto: lib/aesgcm - Reduce stack usage in libaesgcm_init 2024-12-28 19:49:22 +08:00
arc4.c crypto: lib - add missing MODULE_DESCRIPTION() macros 2024-06-07 19:46:39 +08:00
blake2s-generic.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
blake2s-selftest.c crypto: lib/blake2s - Split up test function to halve stack usage 2022-12-30 22:56:27 +08:00
blake2s.c crypto: remove MODULE_LICENSE in non-modules 2023-04-13 13:13:51 -07:00
chacha.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
chacha20poly1305-selftest.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
chacha20poly1305.c crypto: lib/chachapoly - Drop dependency on CRYPTO_ALGAPI 2025-03-08 16:24:36 +08:00
curve25519-fiat32.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
curve25519-generic.c crypto: curve25519 - Fix selftest build error 2020-01-16 15:18:13 +08:00
curve25519-hacl64.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
curve25519-selftest.c crypto: lib/curve25519 - re-add selftests 2019-12-27 18:18:03 +08:00
curve25519.c crypto: lib - rename 'mod_init' & 'mod_exit' functions to be module-specific 2021-07-16 15:49:36 +08:00
des.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
gf128mul.c crypto: lib/gf128mul - Remove some bbe deadcode 2024-12-21 22:46:24 +08:00
Kconfig crypto: lib/chachapoly - Drop dependency on CRYPTO_ALGAPI 2025-03-08 16:24:36 +08:00
libchacha.c crypto: lib - add missing MODULE_DESCRIPTION() macros 2024-06-07 19:46:39 +08:00
Makefile crypto: api - move crypto_simd_disabled_for_test to lib 2024-10-28 18:33:11 +08:00
memneq.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
poly1305-donna32.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
poly1305-donna64.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
poly1305.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
sha1.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
sha256.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00
simd.c crypto: api - move crypto_simd_disabled_for_test to lib 2024-10-28 18:33:11 +08:00
utils.c move asm/unaligned.h to linux/unaligned.h 2024-10-02 17:23:23 -04:00