]> Gentwo Git Trees - linux/.git/commit
lib/crypto: blake2s: Consolidate into single C translation unit
authorEric Biggers <ebiggers@kernel.org>
Wed, 27 Aug 2025 15:11:30 +0000 (08:11 -0700)
committerEric Biggers <ebiggers@kernel.org>
Fri, 29 Aug 2025 16:50:19 +0000 (09:50 -0700)
commit39ee3970f26d55b57343da392d45117d7f893205
tree97ca5c6257117cdfe47b43ceb771f53ffaf276a5
parent5d313a7625fabe9b92eaca7c5ce0e6d1019d279a
lib/crypto: blake2s: Consolidate into single C translation unit

As was done with the other algorithms, reorganize the BLAKE2s code so
that the generic implementation and the arch-specific "glue" code is
consolidated into a single translation unit, so that the compiler will
inline the functions and automatically decide whether to include the
generic code in the resulting binary or not.

Similarly, also consolidate the build rules into
lib/crypto/{Makefile,Kconfig}.  This removes the last uses of
lib/crypto/{arm,x86}/{Makefile,Kconfig}, so remove those too.

Don't keep the !KMSAN dependency.  It was needed only for other
algorithms such as ChaCha that initialize memory from assembly code.

Reviewed-by: Ard Biesheuvel <ardb@kernel.org>
Link: https://lore.kernel.org/r/20250827151131.27733-12-ebiggers@kernel.org
Signed-off-by: Eric Biggers <ebiggers@kernel.org>
12 files changed:
include/crypto/internal/blake2s.h [deleted file]
lib/crypto/Kconfig
lib/crypto/Makefile
lib/crypto/arm/Kconfig [deleted file]
lib/crypto/arm/Makefile [deleted file]
lib/crypto/arm/blake2s-core.S
lib/crypto/arm/blake2s-glue.c [deleted file]
lib/crypto/arm/blake2s.h [new file with mode: 0644]
lib/crypto/blake2s.c
lib/crypto/x86/Kconfig [deleted file]
lib/crypto/x86/Makefile [deleted file]
lib/crypto/x86/blake2s.h [moved from lib/crypto/x86/blake2s-glue.c with 83% similarity]